April 1, 2020
Estimated Post Reading Time ~

How to Increase CQ JVM’s Code Cache Size

CQ can sometimes throw the following error message:

Java HotSpot™ 64-Bit Server VM warning: CodeCache is full. The compiler has been disabled.
Java HotSpot™ 64-Bit Server VM warning: Try increasing the code cache size using -XX:ReservedCodeCacheSize=
Code Cache [0x0000000002260000, 0x0000000008200000, 0x0000000008260000)
total_blobs=21088 nmethods=20310 adapters=692 free_code_cache=1207Kb largest_free_block=418432

When the Code Cache fills, the JVM will stop all further JIT code compilation which can be bad for performance.

To fix this, add the following argument to CQ’s JVM startup arguments list:


-XX:ReservedCodeCacheSize=128m

If the error persists, increase the size from 128 MB to 256 MB.


By aem4beginner

No comments:

Post a Comment

If you have any doubts or questions, please let us know.