mirror of
https://github.com/kubernetes/client-go.git
synced 2025-06-27 15:39:39 +00:00
automatically retry GET requests when http2 connection lost
Kubernetes-commit: 332a094e231942b8b6c2052d078241ddc698fe74
This commit is contained in:
parent
0b9a7d2f21
commit
d69e298e04
@ -1143,7 +1143,7 @@ func (r *Request) request(ctx context.Context, fn func(*http.Request, *http.Resp
|
|||||||
return false
|
return false
|
||||||
}
|
}
|
||||||
// For connection errors and apiserver shutdown errors retry.
|
// For connection errors and apiserver shutdown errors retry.
|
||||||
if net.IsConnectionReset(err) || net.IsProbableEOF(err) {
|
if net.IsConnectionReset(err) || net.IsProbableEOF(err) || net.IsHTTP2ConnectionLost(err) {
|
||||||
return true
|
return true
|
||||||
}
|
}
|
||||||
return false
|
return false
|
||||||
|
Loading…
Reference in New Issue
Block a user