Skip to content

Commit aa45153

Browse files
authored
Merge pull request kubernetes#126954 from deads2k/retry-http2
automatically retry GET requests when http2 connection lost
2 parents 59051eb + 332a094 commit aa45153

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

staging/src/k8s.io/client-go/rest/request.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1143,7 +1143,7 @@ func (r *Request) request(ctx context.Context, fn func(*http.Request, *http.Resp
11431143
return false
11441144
}
11451145
// For connection errors and apiserver shutdown errors retry.
1146-
if net.IsConnectionReset(err) || net.IsProbableEOF(err) {
1146+
if net.IsConnectionReset(err) || net.IsProbableEOF(err) || net.IsHTTP2ConnectionLost(err) {
11471147
return true
11481148
}
11491149
return false

0 commit comments

Comments
 (0)