Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: add retries with backoff to schema download #362

Closed
wants to merge 2 commits into from

Conversation

EverlastingBugstopper
Copy link
Contributor

generally nice to have, might fix the spurious errors we're seeing in CI

Copy link
Contributor

@JakeDawkins JakeDawkins left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I wonder if we'll ever want to build in retries elsewhere, warranting trying to use an external crate with retry abilities

@EverlastingBugstopper
Copy link
Contributor Author

i wish reqwest had a way to do retries but alas, they do not.

@EverlastingBugstopper
Copy link
Contributor Author

this feels reasonable

let max_delay_secs = 30;
let mut has_failed = false;

loop {

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

rather than manually reimplementing this retry logic, might just want to use the retry crate as per here: https://github.com/getditto/ditto/blob/develop/hydra/hydra-common/src/transaction_log.rs#L76. we've already incurred the dependency via hydra-common.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants