-
Notifications
You must be signed in to change notification settings - Fork 822
[Performance]Use threadGroup to compute threads state rather than ThreadMXBean #1235
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
Conversation
Thanks for the contribution! There's a build failure. |
…eadMXBean Signed-off-by: [email protected] <[email protected]>
Signed-off-by: [email protected] <[email protected]>
Sir, thanks for reminding. Have fixed. |
Now fails at JvmThreadsMetricsTest.testGoodCase:86 |
|
compare with the setup in gh actions - probably a different VM of maven version |
Sir, After refer to source code. It is because we don't use ThreadMXBean to compute thread state, so the mocked ThreadMXBean is invalid. |
can you fix it? |
Sir, we can add a config to decide use which way to compute thread state. Then in unit test we still use ThreadMXBean |
what's your proposed fix for the build failure? |
According to the
This change would break users that use nested thread groups - not all VM threads would be observed. |
Environment: jdk-1.8
We encountered performance issue caused by jmx-exporter agent when the thread counts of HDFS Router becoming high.
We have found that it because exporter agent uses ThreadMXBean to compute threads state. It has big performance problem when thread count is high.
More detailes, please refer to https://issues.apache.org/jira/browse/HADOOP-16850