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

Add option to update concurrency #38

Closed
dcolens opened this issue Jun 13, 2018 · 3 comments · Fixed by #52
Closed

Add option to update concurrency #38

dcolens opened this issue Jun 13, 2018 · 3 comments · Fixed by #52

Comments

@dcolens
Copy link

dcolens commented Jun 13, 2018

I have a use case where I need to update concurrency based on queue execution results, what I'd like to do is on a specific output, decrease concurrency (I understand it would not be instant but would have to wait until items are dequeued), maybe the call to decrease concurrency could return a Promise that resolves once the new concurrency is reached ?

@szmarczak
Copy link
Collaborator

Currently that's not possible, but I'll send a PR.

@sindresorhus sindresorhus changed the title option to update concurrency Add option to update concurrency Aug 29, 2018
@sindresorhus
Copy link
Owner

Sounds useful. PR welcome.

@zkochan
Copy link
Contributor

zkochan commented Dec 23, 2018

I think I need this as well to implement pnpm/pnpm#1572

zkochan added a commit to zkochan/p-queue that referenced this issue Dec 23, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants