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
Use CPU count to calculate default no. of buffer processors #17737
Conversation
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.
LGTM.
We have quite a few places where we set these defaults.
https://github.com/search?q=org%3AGraylog2%20processbuffer_processors&type=code
We need to check and potentially remove those
graylog2-server/src/main/java/org/graylog2/plugin/BaseConfiguration.java
Outdated
Show resolved
Hide resolved
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 update! I have one small comment regarding the changelog. The rest looks good! 👍
Co-authored-by: Bernd Ahlers <bernd@users.noreply.github.com>
Calculate default values for process-buffer and output-buffer processors based on the number of CPU cores available to the JVM.
The new defaults will be calculated as illustrated by this graph:
(Highlighted rows represent the predetermined values from #17450.
Fixes #17450
If the number of detected cores is not correct, there are several ways to address that:
-XX:ActiveProcessorCount
as a JVM argument, e.g.-XX:ActiveProcessorCount=2
--cpus
flag, e.g--cpus=2
TODO: