23 .HandleResult<HttpResponseMessage>(r => r.StatusCode == HttpStatusCode.TooManyRequests)
24 .WaitAndRetryAsync(retryCount, attempt =>
26 var calculated = (int)Math.Floor(Math.Pow(2, attempt));
27 var backoff = calculated > maxBackoff.Seconds ? maxBackoff.Seconds : calculated;
28 return TimeSpan.FromSeconds(backoff);