fix(): informer should now reach to changes and not process everything every 2 seconds. also corrected path in probes
This commit is contained in:
@@ -21,8 +21,7 @@ func StartLeaseInformer(cfg *Config, stopCh <-chan struct{}) error {
|
||||
if err != nil {
|
||||
return fmt.Errorf("Could not generate client for informer: %s", err.Error())
|
||||
}
|
||||
|
||||
factory := informers.NewSharedInformerFactoryWithOptions(&client, 0, informers.WithNamespace("kube-system"))
|
||||
factory := informers.NewSharedInformerFactoryWithOptions(client, 0, informers.WithNamespace("kube-system"))
|
||||
leaseInformer := factory.Coordination().V1().Leases().Informer()
|
||||
|
||||
leaseInformer.AddEventHandler(cache.ResourceEventHandlerFuncs{
|
||||
|
||||
Reference in New Issue
Block a user