diff --git a/promlog/log.go b/promlog/log.go index d22a9eea6..cf8307ad2 100644 --- a/promlog/log.go +++ b/promlog/log.go @@ -57,6 +57,7 @@ func (l *AllowedLevel) Set(s string) error { // with a timestamp. The output always goes to stderr. func New(al AllowedLevel) log.Logger { l := log.NewLogfmtLogger(log.NewSyncWriter(os.Stderr)) + l = level.NewFilter(l, al.o) l = log.With(l, "ts", log.DefaultTimestampUTC, "caller", log.DefaultCaller) return l }