mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-28 05:57:25 +00:00
In NodeKiller.Run, wait before first attempt to kill.
This commit is contained in:
parent
25c9ac6544
commit
1d9b1a69b1
@ -349,6 +349,8 @@ func NewNodeKiller(config NodeKillerConfig, client clientset.Interface, provider
|
|||||||
|
|
||||||
// Run starts NodeKiller until stopCh is closed.
|
// Run starts NodeKiller until stopCh is closed.
|
||||||
func (k *NodeKiller) Run(stopCh <-chan struct{}) {
|
func (k *NodeKiller) Run(stopCh <-chan struct{}) {
|
||||||
|
// wait.JitterUntil starts work immediately, so wait first.
|
||||||
|
time.Sleep(wait.Jitter(k.config.Interval, k.config.JitterFactor))
|
||||||
wait.JitterUntil(func() {
|
wait.JitterUntil(func() {
|
||||||
nodes := k.pickNodes()
|
nodes := k.pickNodes()
|
||||||
k.kill(nodes)
|
k.kill(nodes)
|
||||||
|
Loading…
Reference in New Issue
Block a user