17.5. Virtual Threads Support
Infinispan supports virtual threads, which can significantly improve application responsiveness and scalability under high concurrency. By default, they are enabled if you are running on JDK 21 or higher.
On systems with JDK versions prior to 24 and low CPU counts (2 or less), Data Grid might experience thread pinning issues when using virtual threads. Thread pinning is a situation where virtual threads are unexpectedly bound to a limited number of OS threads, potentially leading to performance degradation or system freezes.
To work around this problem, virtual threads can be disabled as described in the procedure below, or the virtual thread scheduler parallelism may be increased with the Java option -Djdk.virtualThreadScheduler.parallelism=<value>. A common starting point for <value> on low-CPU systems is 4.
17.5.1. Disable Virtual Threads リンクのコピーリンクがクリップボードにコピーされました!
Disables the virtual threads pool.
Set the
-Dorg.infinispan.threads.virtual=falseoption in theJAVA_OPTSenvironment variable before starting the Data Grid server.Alternatively, you can append this option directly to the command used to start the Data Grid server:
bin/server.sh -Dorg.infinispan.threads.virtual=falseVerify by checking the server logs. The following log entry should not be present:
Virtual threads support enabled