acme: clarify retries and backoff algorithm
There's been some confusion about failed request retries. Rightfully so: some requests are retried, others are not. This change attempts to clarify the issue and unify backoff usage in all Client's methods by introducing a new exported optional field RetryBackoff and adding retry logic where missing. Also, updates golang/go#22457. Change-Id: Ied434edf998d52925a48b6b3b2407d45a6e9d2ee Reviewed-on: https://go-review.googlesource.com/109615 Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
This commit is contained in:
+1
-1
@@ -104,7 +104,7 @@ func RateLimit(err error) (time.Duration, bool) {
|
||||
if e.Header == nil {
|
||||
return 0, true
|
||||
}
|
||||
return retryAfter(e.Header.Get("Retry-After"), 0), true
|
||||
return retryAfter(e.Header.Get("Retry-After")), true
|
||||
}
|
||||
|
||||
// Account is a user account. It is associated with a private key.
|
||||
|
||||
Reference in New Issue
Block a user