Skip to content

Commit

Permalink
Match stackdriver fluentd logging format (ethereum#83)
Browse files Browse the repository at this point in the history
* Support geth logging to stdout and in JSON format

* Tweak log level to match default fluentd format
  • Loading branch information
timmoreton authored Oct 30, 2018
1 parent 73a7e9a commit 45fb49d
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions log/logger.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ import (
"github.com/go-stack/stack"
)

const timeKey = "t"
const lvlKey = "lvl"
const timeKey = "timestamp"
const lvlKey = "severity"
const msgKey = "msg"
const ctxKey = "ctx"
const errorKey = "LOG15_ERROR"
Expand Down Expand Up @@ -50,17 +50,17 @@ func (l Lvl) AlignedString() string {
func (l Lvl) String() string {
switch l {
case LvlTrace:
return "trce"
return "debug"
case LvlDebug:
return "dbug"
return "debug"
case LvlInfo:
return "info"
case LvlWarn:
return "warn"
return "warning"
case LvlError:
return "eror"
return "error"
case LvlCrit:
return "crit"
return "critical"
default:
panic("bad level")
}
Expand Down

0 comments on commit 45fb49d

Please sign in to comment.