logger_papertrail_backend v1.0.0 LoggerPapertrailBackend.MessageBuilder

Handles building messages that will be sent to Papertrail from Elixir

Summary

Functions

Will build a syslog-message, roughly conforming to a BSD syslogmessage, RFC 3164. But it is specially fitted to work with PaperTrail, http://papertrailapp.com

Functions

build(message, level, hostname, timestamp, tag)
build(message :: binary, level :: atom, hostname :: binary, timestamp :: tuple, tag :: any) :: binary

Will build a syslog-message, roughly conforming to a BSD syslogmessage, RFC 3164. But it is specially fitted to work with PaperTrail, http://papertrailapp.com

Example

iex> LoggerPapertrailBackend.MessageBuilder.build("Hello PaperTrail!", :error, "my_system_name", {{2015,10,1}, {12,44,1}}, "Elixir.Hello.World")
"<11>Oct  1 12:44:01 my_system_name Hello.World Hello PaperTrail!"