-
Notifications
You must be signed in to change notification settings - Fork 418
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
Introduce ThreadPoolExecutor without a Queue #853
Introduce ThreadPoolExecutor without a Queue #853
Conversation
I had a brief look, NICE! Good idea how to get around the problem with 0 already having a meaning. |
Thanks. Look forward to your feedback. |
@pitr-ch any update on this ? |
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.
Thanks a lot! Looks good. Please apply the two suggestions and add a line into a Changelog.
lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb
Outdated
Show resolved
Hide resolved
lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb
Outdated
Show resolved
Hide resolved
This adds the ability for a ThreadPoolExecutor to have a queue depth of 0. This is useful if you'd like to perform the rejection handler if no available threads are availabile. This is analogous to Java's use of SynchronousQueue in ThreadPoolExecutor. See https://stackoverflow.com/a/10186825/143733 for more details
754b4c4
to
7fa7e82
Compare
I've checked and fixed documentation. I had to rebase on master. |
Co-Authored-By: Chalupa Petr <[email protected]>
Co-Authored-By: Chalupa Petr <[email protected]>
Thanks @pitr-ch |
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.
Thanks for the great contribution!
This adds the ability for a ThreadPoolExecutor to have a queue
depth of 0.
This is useful if you'd like to perform the rejection handler if no
available threads are availabile.
This is analogous to Java's use of SynchronousQueue in
ThreadPoolExecutor.
See https://stackoverflow.com/a/10186825/143733 for more details