-
-
Notifications
You must be signed in to change notification settings - Fork 720
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: control queue concurrency #849
Feature: control queue concurrency #849
Conversation
3f14ff3
to
a4802c1
Compare
652494f
to
1c3bdbc
Compare
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #849 +/- ##
==========================================
+ Coverage 68.41% 68.85% +0.43%
==========================================
Files 27 28 +1
Lines 3841 3859 +18
==========================================
+ Hits 2628 2657 +29
+ Misses 929 915 -14
- Partials 284 287 +3 ☔ View full report in Codecov by Sentry. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Overall I think the approach is fine by checking the count of the $queue:lease set. Since this is a major feature and introduces couple of internal changes, I'll let @hibiken comment on the changes first before we proceed to fix any small issues (e.g. tests/coverage).
ec15161
to
07d2722
Compare
I hope this PR can be merged quickly. The current priority queue cannot accurately control the number of consumers in different queues. |
07d2722
to
8f93c46
Compare
@kanzihuang @kamikazechaser This PR is closed. Is there any chance for it to be merged into Master? This is a very important feature. |
#879 is the latest PR around this. I'm yet to get a response from the author. |
// Config specifies the server's background-task processing behavior.
type Config struct {
// Maximum number of concurrent tasks of a queue.
//
// If set to a zero or not set, NewServer will not limit concurrency of the queue.
QueueConcurrency map[string]int
}