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

Feature/retry add optional interval #793

Merged
merged 4 commits into from
Jun 17, 2015

Conversation

edeustace
Copy link
Contributor

I propose adding an optional interval parameter for async.retry, that will introduce a delay between attempts. I have a scenario where I want to retry a call, but not straight away.

This is a non-breaking change.

interval may be passed in as part of an options object as the first parameter to async.retry:

    async.retry({times: 2, interval: 100}, foo, bar);

The existing function signature remains in place:

    async.retry(2, foo, bar); // same as {times: 2, interval: 0}

@aearly aearly added the feature label Jun 17, 2015
aearly added a commit that referenced this pull request Jun 17, 2015
@aearly aearly merged commit bd8325f into caolan:master Jun 17, 2015
@aearly
Copy link
Collaborator

aearly commented Jun 17, 2015

Cool, a nice little enhancement. I also prefer this API to your previous PR. Good work! 💯

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

Successfully merging this pull request may close these issues.

None yet

2 participants