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

zuul-core: Default worker pool size to 2 * processor count #817

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

argha-c
Copy link
Collaborator

@argha-c argha-c commented Jun 2, 2020

In my past experience with Netty, at reasonable scale, a conservative but sane default has been to set the worker pool to 2x the virtual CPU.
This PR sets a ceiling of 8(arguably, a magic number), but more importantly, doubles the worker pool for anything running on lower than 4 cores.

We obviously need to run benchmarks on this, but I believe this is worth reconsidering.

@argha-c argha-c changed the title Default worker pool size to 2 * processor count zuul-core: Default worker pool size to 2 * processor count Jun 10, 2020
@@ -33,7 +33,7 @@

public DefaultEventLoopConfig()
{
eventLoopCount = WORKER_THREADS.get() > 0 ? WORKER_THREADS.get() : PROCESSOR_COUNT;
eventLoopCount = WORKER_THREADS.get() > 0 ? WORKER_THREADS.get() : Math.max(8, PROCESSOR_COUNT*2);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why set a max of 8?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

max is actually the minimum here.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

oh, my bad.

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

Successfully merging this pull request may close these issues.

None yet

3 participants