View Source CozyLogger.JsonFormatter (cozy_logger v0.3.1)
A JSON formatter for Elixir built-in console backend.
usage
Usage
# use Elixir built-in console backend, and configure other necessary options
config :logger,
backends: [:console],
truncate: :infinity,
utc_log: true
# use this formatter
config :logger, :console,
format: {CozyLogger.JsonFormatter, :format},
metadata: :all,
colors: [enabled: false]
Link to this section Summary
Link to this section Functions
@spec format(atom(), term(), Logger.Formatter.time(), keyword()) :: IO.chardata()