dart-lang / labs

This repository is home to Dart 'labs' packages.
BSD 3-Clause "New" or "Revised" License
15 stars 1 forks source link

We should support retries #65

Open sigurdm opened 5 years ago

sigurdm commented 5 years ago

We should (optionally) retry queries that fail with HTTP 5xx and 429 response codes using truncated exponential backoff.

https://cloud.google.com/storage/docs/exponential-backoff outlines how it should be implemented

jonasfj commented 5 years ago

Specifically for 500 and 503: https://cloud.google.com/storage/docs/xml-api/reference-status#500internal-server-error

Probably not for 429... I think that's only likely to make things worse..

jonasfj commented 5 years ago

We can probably just wrap the http.Client return from authClientService with package:http_retry.

As long as we only retry:

See: