Log Format¶
- Author:
Rohit Goswami
Default format (--format=log)¶
Each line follows the pattern:
[TIMESTAMP LEVEL] MESSAGE
Where:
TIMESTAMPis RFC 3339 with second precision (e.g.,2024-01-15T10:30:00Z)LEVELis one of:TRACE,DEBUG,INFO,WARN,ERRORMESSAGEis the original stdout/stderr line
Stdout lines are logged at INFO. Stderr lines are logged at WARN.
JSONL format (--format=jsonl)¶
Each line is a JSON object:
{"ts":"2024-01-15T10:30:00Z","level":"INFO","msg":"gcc -c main.c -o main.o"}
Fields:
Field |
Type |
Description |
|---|---|---|
|
string |
RFC 3339 timestamp |
|
string |
Log level |
|
string |
Original line |
No-timestamp format (--no-timestamp)¶
Applies only to stdout with --format=log. JSONL stdout always includes
ts. Gzip keeps timestamps either way.
Stdout:
[LEVEL] MESSAGE
Gzip file¶
The gzip file always uses the default format with full timestamps, regardless
of --format or --no-timestamp settings. Combined --use-mongodb runs
archive the same levels as a local single file (TRACE through ERROR).
Internal log lines¶
bless adds these internal lines:
TRACElevel: label and UUID at start. Duration at end only when--use-mongodbis not setERRORlevel: command failure messages