Timber v0.4.5 API Reference
Modules
The functions in this module work by modifying the Logger metadata store which is unique to every BEAM process. This is convenient in many ways. First and foremost, it does not require you to manually manage the metadata. Second, because we conform to the standard Logger principles, you can utilize Timber alongside other Logger backends without issue. Timber prefixes its contextual metadata keys so as not to interfere with other systems
The ContextEntry module formalizes the structure of context stack entries
Automatically captures the HTTP request ID in Plug-based frameworks like Phoenix and adds it to the context
A custom context can be specified by the user that is specific to the system being logged
The HTTP context tracks information about an HTTP request currently being handled
The organization context tracks the organization of the currently authenticated user
Tracks process information
The Server context tracks information about the host your system runs on
Tracks a user
Timber integration for Ecto
Handles error reports from the :error_logger
application
A common interface for working with Timber events. That is, anything that
implements the Timber.Eventable
protocol
Automatically logs metadata information about HTTP requests and responses in Plug-based frameworks like Phoenix
Represents a controller being called
Allows for custom events that aren’t covered elsewhere
The exception event is used to track exceptions
The HTTP request event tracks incoming HTTP requests
The HTTP response event tracks outgoing HTTP responses
The SQL Query event tracks SQL query performance
Tracks the time to render a template
The LogEntry module formalizes the structure of every log entry
The Logger module is at the heart of Timber’s integration. It specifies
a backend that can be used with the standard Logger
application distributed
with Elixir
Handles instrumentation of Phoenix.Endpoint
A Transport specifies the way in which Timber.Logger
should actually output
log events
The IODevice transport mechanism allows you to log directly to
stdout
(default; see below) or any other IODevice of your choice
Utility functions for Timber
Exceptions
Error raised when the device being sought is non-existent or otherwise cannot be found or used
Protocols
Converts a data structure to a Timber.Event.t
. This is the heart of how custom events work.
Any value passed in the :timber_event
Logger metadata must implement this