Expand description
An encoder which writes a JSON object adapted from log4rs.
Each log event will be written as a JSON object on its own line.
§Contents
An example object (note that real output will not be pretty-printed):
{
"time": "2016-03-20T14:22:20.644420340-08:00",
"message": "the log message",
"module_path": "foo::bar",
"file": "foo/bar/mod.rs",
"line": 100,
"level": "INFO",
"target": "foo::bar",
"thread": "main",
"thread_id": 123,
"mdc": {
"request_id": "123e4567-e89b-12d3-a456-426655440000"
}
"node_info": {
}
}Structs§
- CONTEXT_
INFO - Json
Encoder - An
Encoder which writes a JSON object.