Closed StandardMikeBenza closed 6 months ago
Hello @StandardMikeBenza, this was true but behaviour is changed in master
branch and now it's not specific to the package. Logger in the latest Elixir versions works on top of Erlang one and it supplies time
as a metadata attribute to the formatters. Not sure if you can override it now or now, but closing since there is nothing we can do about it.
I recently debugged an issue where my log messages weren't showing up as expected. I had introduced a log message that had
time
metadata (how long an operation took). Since LoggerJSON.Formatters.GoogleCloudLogger merges the metadata into the map oftime
,severity
, andmessage
, metadatatime
replaced the actual timestamp. The same would happen forseverity
ormessage
.This should at a minimum be documented. Ideally the
time
,severity
, andmessage
would be merged into the metadata. A plus would be some way of warning that the original value had been overwritten and recording the original value.