Skip to content

Commit 48ead4e

Browse files
authored
Merge pull request kubernetes#128648 from pohly/dra-scheduler-perf-flake
scheduler_perf: fix steady-state pod creation/deletion
2 parents 9729ac8 + 0301b6b commit 48ead4e

File tree

1 file changed

+9
-2
lines changed

1 file changed

+9
-2
lines changed

test/integration/scheduler_perf/scheduler_perf.go

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1953,12 +1953,19 @@ func createPodsSteadily(tCtx ktesting.TContext, namespace string, podInformer co
19531953
}, metav1.ListOptions{})
19541954
// Ignore errors when the time is up. errors.Is(context.Canceled) would
19551955
// be more precise, but doesn't work because client-go doesn't reliably
1956-
// propagate it. Instead, this was seen:
1957-
// client rate limiter Wait returned an error: rate: Wait(n=1) would exceed context deadline
1956+
// propagate it.
19581957
if tCtx.Err() != nil {
19591958
continue
19601959
}
19611960
if err != nil {
1961+
// Worse, sometimes rate limiting gives up *before* the context deadline is reached.
1962+
// Then we get here with this error:
1963+
// client rate limiter Wait returned an error: rate: Wait(n=1) would exceed context deadline
1964+
//
1965+
// This also can be ignored. We'll retry if the test is not done yet.
1966+
if strings.Contains(err.Error(), "would exceed context deadline") {
1967+
continue
1968+
}
19621969
return fmt.Errorf("delete scheduled pods: %w", err)
19631970
}
19641971
err = strategy(tCtx, tCtx.Client(), namespace, cpo.Count)

0 commit comments

Comments
 (0)