Change default informer resync period to 30 minutes (#2167)
Currently most of informers used in Fission are using resync period of 30sec which is quite low and causes lot of disturbances in overall system. Since informers already have watchers which would be delivering events to the handlers. If any handlers require lower sync period they should register handler with `AddEventHandlersWithResyncPeriod` instead of we generaling informer. Signed-off-by: Sanket Sudake <sanketsudake@gmail.com>
This commit is contained in:
@@ -275,7 +275,7 @@ func StartExecutor(logger *zap.Logger, functionNamespace string, envBuilderNames
|
||||
|
||||
logger.Info("Starting executor", zap.String("instanceID", executorInstanceID))
|
||||
|
||||
informerFactory := genInformer.NewSharedInformerFactory(fissionClient, time.Second*30)
|
||||
informerFactory := genInformer.NewSharedInformerFactory(fissionClient, time.Minute*30)
|
||||
funcInformer := informerFactory.Core().V1().Functions().Informer()
|
||||
pkgInformer := informerFactory.Core().V1().Packages().Informer()
|
||||
envInformer := informerFactory.Core().V1().Environments().Informer()
|
||||
@@ -330,7 +330,7 @@ func StartExecutor(logger *zap.Logger, functionNamespace string, envBuilderNames
|
||||
// TODO: use context to control the waiting time once kubernetes client supports it.
|
||||
util.WaitTimeout(wg, 30*time.Second)
|
||||
|
||||
k8sInformerFactory := k8sInformers.NewSharedInformerFactory(kubernetesClient, time.Second*30)
|
||||
k8sInformerFactory := k8sInformers.NewSharedInformerFactory(kubernetesClient, time.Minute*30)
|
||||
configmapInformer := k8sInformerFactory.Core().V1().ConfigMaps().Informer()
|
||||
secretInformer := k8sInformerFactory.Core().V1().Secrets().Informer()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user