Skip to content

Make time units clear for retry configuration #154

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

Closed
Tyler-Murphy opened this issue Aug 20, 2019 · 3 comments
Closed

Make time units clear for retry configuration #154

Tyler-Murphy opened this issue Aug 20, 2019 · 3 comments
Assignees
Labels
type: docs Improvement to the documentation for an API.

Comments

@Tyler-Murphy
Copy link

No units are specified for the retryDelay option, which makes it hard to be sure what the value represents.

    // The amount of time to initially delay the retry.  Defaults to 100.
    retryDelay?: number;

I was using the option in a library that uses gaxios as a dependency of a dependency, so I had to dig through multiple layers to end up in the source code here to confirm that it uses milliseconds.

It'd be helpful for the units of the number to be in the option name, so that it's called something like retryDelayMilliseconds. Or even better, initialRetryDelayMilliseconds.

I didn't look through all other options to see whether they're missing units, but generally, I think it's helpful for all units to be specified wherever possible, to reduce ambiguity.

@yoshi-automation yoshi-automation added the triage me I really want to be triaged. label Aug 21, 2019
@stephenplusplus stephenplusplus added type: docs Improvement to the documentation for an API. type: feature request ‘Nice-to-have’ improvement, new feature or different behavior or design. and removed triage me I really want to be triaged. triage me labels Aug 22, 2019
@JustinBeckwith JustinBeckwith removed the type: feature request ‘Nice-to-have’ improvement, new feature or different behavior or design. label Oct 16, 2019
@JustinBeckwith
Copy link
Contributor

That's a really great call, and thank you for the issue! Kind of a good news / bad news update here. Turns out - we were never actually using the retryDelay property (#143)

Instead of trying to nuance this in with the exponential backoff in place, we decided to remove the option all together in #203.

@Tyler-Murphy
Copy link
Author

Oh no! Well, thanks for the update.

Are retries happening even though the retryDelay option wasn't doing anything? It sounds like they are, but I'd like to confirm it.

@JustinBeckwith
Copy link
Contributor

Oh yeah, of course. It's just that the backoff strategy I'm place appears to work pretty well, and I didn't want to mess with it.

@JustinBeckwith JustinBeckwith self-assigned this Feb 1, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: docs Improvement to the documentation for an API.
Projects
None yet
Development

No branches or pull requests

4 participants