jetty.project/tests
Simone Bordet 278ec1be69
Fixes #9237 - Decouple QTP idleTimeout from pool shrink rate. (#9498)
Introduced `QueuedThreadPool.maxEvictCount` to be the number of idle threads that are evicted in one idle timeout.

When set to 1 (the default), the old behavior is reproduced: expiring 1 thread every idle timeout.
When set to larger values, allows to keep around the threads for the idle timeout (in case of further load spikes), but allows to quickly recover OS memory when they are truly idle.

For example, with 2000 threads, 30 seconds idle timeout and idleTimeoutMaxShrinkCount=1, it will take 995 minutes (about 16.5 hrs) to shrink the pool back to 10 threads.
By setting idleTimeoutMaxShrinkCount=100, the thread pool can be shrunk to 10 threads in about 10 minutes.

Note also that the new algorithm is more aggressive at shrinking the thread pool.
Previously, a small load might have been sufficient to never evict any thread, because all threads could take turns at executing jobs so that threads were mostly idle but would never really idle time out.
The new algorithm is more aggressive even in presence of a small load, so that if `minThreads` are sufficient to cope with the small load, then the other threads are evicted.

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
Signed-off-by: gregw <gregw@webtide.com>
Signed-off-by: Ludovic Orban <lorban@bitronix.be>
Co-authored-by: gregw <gregw@webtide.com>
Co-authored-by: Ludovic Orban <lorban@bitronix.be>
2023-03-31 15:36:34 +02:00
..
jetty-home-tester no need of unzip jetty-home for every single test if it is the same zip (based on lastModified file value) (#9486) 2023-03-11 10:21:39 +10:00
jetty-http-tools Updating to version 10.0.15-SNAPSHOT 2023-03-01 18:55:10 +10:00
jetty-jmh Fixes #9237 - Decouple QTP idleTimeout from pool shrink rate. (#9498) 2023-03-31 15:36:34 +02:00
test-cdi Updating to version 10.0.15-SNAPSHOT 2023-03-01 18:55:10 +10:00
test-distribution Updating to version 10.0.15-SNAPSHOT 2023-03-01 18:55:10 +10:00
test-http-client-transport Updating to version 10.0.15-SNAPSHOT 2023-03-01 18:55:10 +10:00
test-integration Updating to version 10.0.15-SNAPSHOT 2023-03-01 18:55:10 +10:00
test-jmx Updating to version 10.0.15-SNAPSHOT 2023-03-01 18:55:10 +10:00
test-jpms Updating to version 10.0.15-SNAPSHOT 2023-03-01 18:55:10 +10:00
test-loginservice Updating to version 10.0.15-SNAPSHOT 2023-03-01 18:55:10 +10:00
test-quickstart Updating to version 10.0.15-SNAPSHOT 2023-03-01 18:55:10 +10:00
test-sessions Disable broken JDK19 test 2023-03-21 07:40:02 -05:00
test-webapps Updating to version 10.0.15-SNAPSHOT 2023-03-01 18:55:10 +10:00
test-websocket-autobahn Updating to version 10.0.15-SNAPSHOT 2023-03-01 18:55:10 +10:00
pom.xml Updating to version 10.0.15-SNAPSHOT 2023-03-01 18:55:10 +10:00