File tree Expand file tree Collapse file tree 1 file changed +10
-1
lines changed Expand file tree Collapse file tree 1 file changed +10
-1
lines changed Original file line number Diff line number Diff line change @@ -18,6 +18,7 @@ package nfdgarbagecollector
1818
1919import (
2020 "context"
21+ "fmt"
2122 "time"
2223
2324 topologyclientset "github.com/k8stopologyawareschedwg/noderesourcetopology-api/pkg/generated/clientset/versioned"
@@ -208,7 +209,15 @@ func (n *nfdGarbageCollector) startNodeInformer() error {
208209
209210 // start informers
210211 n .factory .Start (n .stopChan )
211- n .factory .WaitForCacheSync (n .stopChan )
212+
213+ start := time .Now ()
214+ ret := n .factory .WaitForCacheSync (n .stopChan )
215+ for res , ok := range ret {
216+ if ! ok {
217+ return fmt .Errorf ("node informer cache failed to sync (%s)" , res )
218+ }
219+ }
220+ klog .InfoS ("node informer cache synced" , "duration" , time .Since (start ))
212221
213222 return nil
214223}
You can’t perform that action at this time.
0 commit comments