From fd972934e4916879b04508686302659ce82cfa75 Mon Sep 17 00:00:00 2001 From: Patrick Ohly Date: Thu, 10 Jun 2021 20:36:02 +0200 Subject: [PATCH] client-go: reduce log level of reflector again https://github.com/kubernetes/kubernetes/pull/87795 most likely unintentionally increased the log level of "Starting reflector" and "Stopping reflector", with the result that since Kubernetes 1.21 clients have printed that message by default. This is undesirable, we should use the original level 3 again. --- staging/src/k8s.io/client-go/tools/cache/reflector.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/staging/src/k8s.io/client-go/tools/cache/reflector.go b/staging/src/k8s.io/client-go/tools/cache/reflector.go index c732c782207..90fa45ddbfe 100644 --- a/staging/src/k8s.io/client-go/tools/cache/reflector.go +++ b/staging/src/k8s.io/client-go/tools/cache/reflector.go @@ -216,13 +216,13 @@ var internalPackages = []string{"client-go/tools/cache/"} // objects and subsequent deltas. // Run will exit when stopCh is closed. func (r *Reflector) Run(stopCh <-chan struct{}) { - klog.V(2).Infof("Starting reflector %s (%s) from %s", r.expectedTypeName, r.resyncPeriod, r.name) + klog.V(3).Infof("Starting reflector %s (%s) from %s", r.expectedTypeName, r.resyncPeriod, r.name) wait.BackoffUntil(func() { if err := r.ListAndWatch(stopCh); err != nil { r.watchErrorHandler(r, err) } }, r.backoffManager, true, stopCh) - klog.V(2).Infof("Stopping reflector %s (%s) from %s", r.expectedTypeName, r.resyncPeriod, r.name) + klog.V(3).Infof("Stopping reflector %s (%s) from %s", r.expectedTypeName, r.resyncPeriod, r.name) } var (