Hi, I am wondering if anyone has some experience or thoughts about tuning numWorkerThreads in CommitProcessor.
I ran load tests against ZK 3.7 with different settings of numWorkerThreads and found that it didn't make any considerable difference in terms of both throughput and latency. The test I ran is 500 concurrent users sending read requests. The data size to read is 4 bytes. The Zk server in my test has 4 cpu cores, so I tested with 8, 4, 2 and 0 worker threads. The test results are very similar. The throughput is all around 200k/s and the latency is around 4ms. When setting the worker threads to 0, it means that the main thread is also responsible for reading the data from the data tree and sending out the response. In theory it should have some performance difference between 8 vs 0 workers. I am thinking the possible reasons for the test results are: 1. Reading data and sending the response is not the performance bottleneck, as the data is in memory and data size is only 4 bytes. 2. Even adding more workers has some improvement, given the amount of load generated in the test and perf data we have (i.e. 200k/s throughput, 4ms latency), the difference would be hard to see. I wonder if anyone has any thoughts on this. Thanks, Li