Unverified Commit dbdcb7e0 authored by k8s-ci-robot's avatar k8s-ci-robot Committed by GitHub

Merge pull request #70072 from yue9944882/chore/cleanup-serviceaccount-controller-options

Fixes wild serviceaccount controller resync options
parents 15c15bed 4624c131
......@@ -73,16 +73,16 @@ func NewServiceAccountsController(saInformer coreinformers.ServiceAccountInforme
}
}
saInformer.Informer().AddEventHandler(cache.ResourceEventHandlerFuncs{
saInformer.Informer().AddEventHandlerWithResyncPeriod(cache.ResourceEventHandlerFuncs{
DeleteFunc: e.serviceAccountDeleted,
})
}, options.ServiceAccountResync)
e.saLister = saInformer.Lister()
e.saListerSynced = saInformer.Informer().HasSynced
nsInformer.Informer().AddEventHandler(cache.ResourceEventHandlerFuncs{
nsInformer.Informer().AddEventHandlerWithResyncPeriod(cache.ResourceEventHandlerFuncs{
AddFunc: e.namespaceAdded,
UpdateFunc: e.namespaceUpdated,
})
}, options.NamespaceResync)
e.nsLister = nsInformer.Lister()
e.nsListerSynced = nsInformer.Informer().HasSynced
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment