Skip to content

Commit

Permalink
UTC ns logging fixes #150
Browse files Browse the repository at this point in the history
  • Loading branch information
mantzas authored Jul 31, 2018
1 parent ee7d4e3 commit 3f6b135
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions log/zerolog/factory.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ package zerolog

import (
"os"
"time"

"github.com/mantzas/patron/log"
"github.com/rs/zerolog"
Expand All @@ -22,6 +23,7 @@ func NewFactory(l *zerolog.Logger, lvl log.Level) log.Factory {
func DefaultFactory(lvl log.Level) log.Factory {
zerolog.LevelFieldName = "lvl"
zerolog.MessageFieldName = "msg"
zerolog.TimeFieldFormat = time.RFC3339Nano
zl := zerolog.New(os.Stdout).With().Timestamp().Logger()
return NewFactory(&zl, lvl)
}
Expand Down

0 comments on commit 3f6b135

Please sign in to comment.