mirror of https://github.com/k3s-io/k3s
Merge pull request #42940 from caesarxuchao/fix-gc-orphan-rs
Automatic merge from submit-queue (batch tested with PRs 42940, 42906, 42970, 42848) Increase timeout for the orphan e2e test Fix #42086. Analysis of test logs are in https://github.com/kubernetes/kubernetes/issues/42086#issuecomment-285770868 and the following comments. @deads2k PTAL, thanks!pull/6/head
commit
d60d965f33
|
@ -283,7 +283,13 @@ var _ = framework.KubeDescribe("Garbage collector", func() {
|
|||
framework.Failf("failed to delete the rc: %v", err)
|
||||
}
|
||||
By("wait for the rc to be deleted")
|
||||
if err := wait.Poll(5*time.Second, 30*time.Second, func() (bool, error) {
|
||||
// Orphaning the 100 pods takes 100 PATCH operations. The default qps of
|
||||
// a client is 5. If the qps is saturated, it will take 20s to orphan
|
||||
// the pods. However, apiserver takes hundreds of ms to finish one
|
||||
// PATCH, and the gc sends the patching in a single thread, so the
|
||||
// actual qps is less than 5. According to the test logs, 60s is enough
|
||||
// time.
|
||||
if err := wait.Poll(5*time.Second, 60*time.Second, func() (bool, error) {
|
||||
rcs, err := rcClient.List(metav1.ListOptions{})
|
||||
if err != nil {
|
||||
return false, fmt.Errorf("Failed to list rcs: %v", err)
|
||||
|
|
Loading…
Reference in New Issue