Closed stephanos closed 6 years ago
@stephanos OK. I'll add it to the TODO list.
@stephanos I didn't realize that you can actually use expiry/2
to solve your problem. I'm closing this issue for now, but feel free to reopen it if necessary.
ah, that's true! awesome, thank you!
In our code we are communicating with an external system that has "good and bad days". When it has a bad day, it will take a very long time to reply (timeout is 45s). Our default strategy is 5 retries with linear backoff, but we know that we won't get a response at all if we already had 2 retries with a total wait time of 90s - there is no need to retry 3 times more.
Would it be possible to add a total retry limit? Something like this maybe:
To solve it ourselves we added a bunch of timings (
started_time
andelapsed_time
) and then need to fake a return:ok
when we passed the maximum retry time. Very awkward.