View Source StructuredLogger (StructuredLogger v0.0.1)

A logger formatter focused on structured logging.

Link to this section Summary

Functions

Receives the description of a log and outputs a string with a formatted log

Link to this section Functions

Link to this function

format(level, message, timestamp, metadata)

View Source
@spec format(atom(), String.t(), tuple(), Keyword.t()) :: String.t()

Receives the description of a log and outputs a string with a formatted log

parameters

Parameters

  • level: The logging level that describes how critical is this log message
  • message: An iodata with the actual log message
  • timestamp: A tuple representing the log timestamp
  • metadata: A Keyword list with additional metadata related to the log