You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@zookeeper.apache.org by GitBox <gi...@apache.org> on 2022/03/12 12:54:40 UTC
[GitHub] [zookeeper] kezhuw opened a new pull request #1836: Fix flaky test RequestPathMetricsCollectorTest#testMultiThreadPerf
kezhuw opened a new pull request #1836:
URL: https://github.com/apache/zookeeper/pull/1836
This test is asserting low performance threshold for
RequestPathMetricsCollector#registerRequest. It fails at rate 20%
according to jira reports. I think it caused by combination of:
1. Unstable test environment.
2. `Executors.newCachedThreadPool` is not suitable for cpu-bound
operations.
3. `System.currentTimeMillis` is not suitable for time counting due to
possible wall clock skewing.
This pr try to fix flakyness through:
1. Increase timeout for unstable test environment.
2. Use `Executors.newWorkStealingPool` to execute register operation.
3. Use `System.nanoTime` to count elapsed time.
Additionally, it logs elapsed time for performance measurement.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@zookeeper.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org