This PR aims to configure a json format for our logs using LoggerJSON to improve usability in datadog.
Implementation Details
We created a fork of the library LoggerJSON so we can use it in house.
We also created and configured a datadog_logger module based on an existent formatter (but still not released) from the same library.
By changing and customizing some log fields, datadog can now understand log severity, timestamp, mfa, etc as the image below:
To make it work, we changed the attribute message to msg and configured a message remapper in datadog specific for our service:
Proposal
Jira Card: PIXBR-359
This PR aims to configure a json format for our logs using LoggerJSON to improve usability in datadog.
Implementation Details
We created a fork of the library LoggerJSON so we can use it in house. We also created and configured a
datadog_logger
module based on an existent formatter (but still not released) from the same library. By changing and customizing some log fields, datadog can now understand log severity, timestamp, mfa, etc as the image below:To make it work, we changed the attribute
message
tomsg
and configured a message remapper in datadog specific for our service: