From 13d5cd3e21e1ecac4db7f780fe2a5b2b245ffaf7 Mon Sep 17 00:00:00 2001 From: Dmitrii Stepanov Date: Mon, 19 Feb 2024 13:08:18 +0300 Subject: [PATCH] [#991] logger: Fix journald logger Allow to change logger level. Signed-off-by: Dmitrii Stepanov --- pkg/util/logger/logger.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkg/util/logger/logger.go b/pkg/util/logger/logger.go index c6db04df9..e67afb36b 100644 --- a/pkg/util/logger/logger.go +++ b/pkg/util/logger/logger.go @@ -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(), -- 2.45.2