mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-28 22:17:14 +00:00
Merge pull request #62155 from soltysh/issue61484
Automatic merge from submit-queue (batch tested with PRs 62063, 62169, 62155, 62139, 61445). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.
Wait longer in pod cleanup
I've checked the [garbage collector tests](827b3d77cd/test/e2e/apimachinery/garbage_collector.go (L557)
) and usually they're waiting up to a minute to clean the resources. So I'm proposing to use that same values when waiting for the pod cleanup. I was not able to reproduce the problem locally, but from reading the logs it looks like the problem might be with just the timing nothing else.
Related to #61484
/assign @Liujingfang1 @mengqiy
This commit is contained in:
commit
efeb1db2b0
@ -2077,11 +2077,6 @@ func AssertCleanup(ns string, selectors ...string) {
|
|||||||
nsArg = fmt.Sprintf("--namespace=%s", ns)
|
nsArg = fmt.Sprintf("--namespace=%s", ns)
|
||||||
}
|
}
|
||||||
|
|
||||||
backoff := wait.Backoff{
|
|
||||||
Duration: 5 * time.Second,
|
|
||||||
Factor: 2,
|
|
||||||
Steps: 3,
|
|
||||||
}
|
|
||||||
var e error
|
var e error
|
||||||
verifyCleanupFunc := func() (bool, error) {
|
verifyCleanupFunc := func() (bool, error) {
|
||||||
e = nil
|
e = nil
|
||||||
@ -2099,7 +2094,7 @@ func AssertCleanup(ns string, selectors ...string) {
|
|||||||
}
|
}
|
||||||
return true, nil
|
return true, nil
|
||||||
}
|
}
|
||||||
err := wait.ExponentialBackoff(backoff, verifyCleanupFunc)
|
err := wait.PollImmediate(500*time.Millisecond, 1*time.Minute, verifyCleanupFunc)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
Failf(e.Error())
|
Failf(e.Error())
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user