<div class="__aliyun_email_body_block"><div style="line-height:1.7;font-family:Tahoma,Arial,STHeiti,SimSun;font-size:14.0px;color:#000000;"><div style="clear:both;"><br ></div><div style="clear:both;">Hi I know, it was suggested that not pooling the <span >VirtualThread, when I replace my old executors to use the fancy new `VirtualThreadExecutorFactory` and with the </span></div><div style="clear:both;"><span ><span >`jdk.virtualThreadScheduler.maxPoolSize` set to 2500</span></span></div><div style="clear:both;"><span ><span ><br ></span></span></div><div style="clear:both;"><span ><span >after some load testing and the thread size grow to <span >2205 </span></span></span></div><div style="clear:both;"><span ><span ><span ><br ></span></span></span></div><div style="clear:both;">and even the stress testing is removed from the system , the thread never adjust to a smaller one. </div><div style="clear:both;"><br ></div><div style="clear:both;">I will change my code to not pooling the virtual thread then.</div><div style="clear:both;"><br ></div><div style="clear:both;">eg:</div><div style="clear:both;"><br ></div><div style="clear:both;"><pre data-spm-anchor-id="a1zd2.nodethread.0.i5.12be22c6z7nlpC" style="box-sizing:border-box;overflow:auto;font-family:Menlo,Monaco,Consolas,'Courier New',monospace;font-size:13.0px;display:block;padding:9.5px;margin:.0px .0px 10.0px;color:#333333;word-break:break-all;overflow-wrap:break-word;background-color:#f5f5f5;border:1.0px solid #cccccc;border-radius:4.0px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:.0px;text-transform:none;word-spacing:.0px;text-decoration-thickness:initial;text-decoration-style:initial;text-decoration-color:initial;">"ForkJoinPool-3-worker-2173" Id=51031 WAITING on java.util.concurrent.ForkJoinPool@20ccd17
at java.base@21.0.1.0.1/jdk.internal.misc.Unsafe.park(Native Method)
- waiting on java.util.concurrent.ForkJoinPool@20ccd17
at java.base@21.0.1.0.1/java.util.concurrent.locks.LockSupport.park(LockSupport.java:371)
at java.base@21.0.1.0.1/java.util.concurrent.ForkJoinPool.awaitWork(ForkJoinPool.java:1893)
at java.base@21.0.1.0.1/java.util.concurrent.ForkJoinPool.runWorker(ForkJoinPool.java:1809)
at java.base@21.0.1.0.1/java.util.concurrent.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:188)</pre></div></div></div>