Closed hazen closed 6 years ago
@javajolt You should be able to achieve the same result just by increasing the timeout. If you want to allow 50 retries with a 20s timeout, seems you could just use a 1000s timeout instead.
Thanks for the feedback, @maxcnunes. The use case I'm trying to address here is a slowly starting service which needs very infrequent checks. The default was filling our logs with retry messages, but if we can back off the retry interval, then we get fewer messages. We still like the messages, just fewer of them. Also it is less resource-intensive by polling the local service less frequently. It seems to work for our development needs.
Maybe there was some configuration I was missing or misunderstanding. The sleep interval looked fixed it me.
Alright, that seems reasonable. Thanks for the PR 👏 I will just cover that new part with unit tests before publishing it.
This will allow the time between retries to be specified. It is useful for services which are slow in responding to avoid hammering the down service.