From 74c69749ec996bacf00e91c04890b6e90ac0b8fd Mon Sep 17 00:00:00 2001 From: ferhat elmas Date: Wed, 21 Feb 2024 11:09:58 +0100 Subject: [PATCH] Make 520 status code retryable (#1935) --- retry.go | 1 + 1 file changed, 1 insertion(+) diff --git a/retry.go b/retry.go index 1c6105e6a..5ddcad897 100644 --- a/retry.go +++ b/retry.go @@ -118,6 +118,7 @@ var retryableHTTPStatusCodes = map[int]struct{}{ http.StatusBadGateway: {}, http.StatusServiceUnavailable: {}, http.StatusGatewayTimeout: {}, + 520: {}, // It is used by Cloudflare as a catch-all response for when the origin server sends something unexpected. // Add more HTTP status codes here. }