Add support for the bunyan JSON log format

See https://github.com/trentm/node-bunyan
pull/1136/head
Tobias Gruetzmacher 2 years ago
parent 33a80db95c
commit d675a8d10e
No known key found for this signature in database

@ -0,0 +1,73 @@
{
"$schema": "https://lnav.org/schemas/format-v1.schema.json",
"bunyan": {
"title": "Bunyan log",
"url": "https://github.com/trentm/node-bunyan",
"description": "Bunyan JSON logging library for node.js",
"json": true,
"line-format": [
{
"field": "time"
},
" ",
{
"field": "name"
},
"[",
{
"field": "pid"
},
"] ",
{
"field": "__level__",
"text-transform": "uppercase"
},
" ",
{
"field": "msg"
}
],
"level-field": "level",
"level": {
"fatal": "60",
"error": "50",
"warning": "40",
"info": "30",
"debug": "20",
"trace": "10"
},
"value": {
"pid": {
"kind": "integer",
"identifier": true
},
"name": {
"kind": "string",
"identifier": true
},
"hostname": {
"kind": "string",
"identifier": true,
"hidden": true
},
"time": {
"kind": "string",
"identifier": false
},
"level": {
"kind": "integer",
"identifier": true,
"foreign-key": true
},
"v": {
"kind": "integer",
"hidden": true
},
"msg": {
"kind": "string"
}
},
"timestamp-field": "time",
"body-field": "msg"
}
}

@ -3,6 +3,7 @@ FORMAT_FILES = \
$(srcdir)/%reldir%/access_log.json \
$(srcdir)/%reldir%/alb_log.json \
$(srcdir)/%reldir%/block_log.json \
$(srcdir)/%reldir%/bunyan_log.json \
$(srcdir)/%reldir%/candlepin_log.json \
$(srcdir)/%reldir%/choose_repo_log.json \
$(srcdir)/%reldir%/cups_log.json \

Loading…
Cancel
Save