Skip to content

Commit

Permalink
Retry net.ErrClosed (#1637)
Browse files Browse the repository at this point in the history
  • Loading branch information
jonjohnsonjr committed Apr 9, 2023
1 parent 2435320 commit ed5c185
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/v1/remote/options.go
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ type Backoff = retry.Backoff
var defaultRetryPredicate retry.Predicate = func(err error) bool {
// Various failure modes here, as we're often reading from and writing to
// the network.
if retry.IsTemporary(err) || errors.Is(err, io.ErrUnexpectedEOF) || errors.Is(err, io.EOF) || errors.Is(err, syscall.EPIPE) || errors.Is(err, syscall.ECONNRESET) {
if retry.IsTemporary(err) || errors.Is(err, io.ErrUnexpectedEOF) || errors.Is(err, io.EOF) || errors.Is(err, syscall.EPIPE) || errors.Is(err, syscall.ECONNRESET) || errors.Is(err, net.ErrClosed) {
logs.Warn.Printf("retrying %v", err)
return true
}
Expand Down

0 comments on commit ed5c185

Please sign in to comment.