logging: Tweak defaults (enable logging by default, color level enc.)

This commit is contained in:
Matthew Holt 2019-10-29 11:58:29 -06:00
parent 54e458b756
commit c4c45f8e01
No known key found for this signature in database
GPG key ID: 2A349DD577D586A5
2 changed files with 7 additions and 5 deletions

View file

@ -577,6 +577,7 @@ func newDefaultProductionLog() (*defaultCustomLog, error) {
return nil, err
}
encCfg := zap.NewProductionEncoderConfig()
encCfg.EncodeLevel = zapcore.CapitalColorLevelEncoder
cl.encoder = zapcore.NewConsoleEncoder(encCfg)
cl.levelEnabler = zapcore.InfoLevel