[#991] logger: Fix journald logger
All checks were successful
DCO action / DCO (pull_request) Successful in 1m7s
Vulncheck / Vulncheck (pull_request) Successful in 3m32s
Build / Build Components (1.22) (pull_request) Successful in 3m52s
Build / Build Components (1.21) (pull_request) Successful in 3m58s
Tests and linters / Lint (pull_request) Successful in 5m13s
Tests and linters / Tests (1.22) (pull_request) Successful in 7m22s
Tests and linters / Tests (1.21) (pull_request) Successful in 7m34s
Tests and linters / Tests with -race (pull_request) Successful in 7m32s
Tests and linters / Staticcheck (pull_request) Successful in 2m22s
All checks were successful
DCO action / DCO (pull_request) Successful in 1m7s
Vulncheck / Vulncheck (pull_request) Successful in 3m32s
Build / Build Components (1.22) (pull_request) Successful in 3m52s
Build / Build Components (1.21) (pull_request) Successful in 3m58s
Tests and linters / Lint (pull_request) Successful in 5m13s
Tests and linters / Tests (1.22) (pull_request) Successful in 7m22s
Tests and linters / Tests (1.21) (pull_request) Successful in 7m34s
Tests and linters / Tests with -race (pull_request) Successful in 7m32s
Tests and linters / Staticcheck (pull_request) Successful in 2m22s
Allow to change logger level. Signed-off-by: Dmitrii Stepanov <d.stepanov@yadro.com>
This commit is contained in:
parent
f3e50772fd
commit
13d5cd3e21
1 changed files with 1 additions and 1 deletions
|
@ -147,7 +147,7 @@ func newJournaldLogger(prm *Prm) (*Logger, error) {
|
|||
|
||||
encoder := zapjournald.NewPartialEncoder(zapcore.NewConsoleEncoder(c.EncoderConfig), zapjournald.SyslogFields)
|
||||
|
||||
core := zapjournald.NewCore(zap.NewAtomicLevelAt(prm.level), encoder, &journald.Journal{}, zapjournald.SyslogFields)
|
||||
core := zapjournald.NewCore(lvl, encoder, &journald.Journal{}, zapjournald.SyslogFields)
|
||||
coreWithContext := core.With([]zapcore.Field{
|
||||
zapjournald.SyslogFacility(zapjournald.LogDaemon),
|
||||
zapjournald.SyslogIdentifier(),
|
||||
|
|
Loading…
Reference in a new issue