From 898cf6eb489f1b599b1c31a3ffe2266caa79ef4f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcel=20Zi=C4=99ba?= Date: Fri, 30 Apr 2021 08:29:01 +0000 Subject: [PATCH] Add jitter to lease controller --- .../k8s.io/component-helpers/apimachinery/lease/controller.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/staging/src/k8s.io/component-helpers/apimachinery/lease/controller.go b/staging/src/k8s.io/component-helpers/apimachinery/lease/controller.go index 3b31c80a7a0..517351a3b4d 100644 --- a/staging/src/k8s.io/component-helpers/apimachinery/lease/controller.go +++ b/staging/src/k8s.io/component-helpers/apimachinery/lease/controller.go @@ -95,7 +95,7 @@ func (c *controller) Run(stopCh <-chan struct{}) { klog.Infof("lease controller has nil lease client, will not claim or renew leases") return } - wait.Until(c.sync, c.renewInterval, stopCh) + wait.JitterUntil(c.sync, c.renewInterval, 0.04, true, stopCh) } func (c *controller) sync() {