Currently JVM does not have any feature to call full GC periodically. Releasing reserved, but at the same time unused RAM by JVM to OS is required for automatic vertical scaling, configured in Jelastic Cloud. That’s why Jelastic uses a special Garbage Collection agent.
|Jelastic GC agent has a smart algorithm for monitoring consumed and free RAM. While processing monitoring outcomes, it recognizes the possibility to release a portion of RAM to OS that results in calling Full GC. If JVM does not have free RAM which can be released to OS, then Jelastic GC agent does not call Full GC. That brings the possibility of app performance degradation to zero.|
Jelastic GC agent works only for two kinds of Garbage Collection (set in Jelastic by default):
If you change the default GC settings to any other which does not provide compaction and can not release RAM to OS by design, then Jelastic GC Agent will be disabled and won’t call Full GC.
To tune the settings of Jelastic GC agent, navigate to the server > variables.conf file for Tomcat, TomEE or Jetty application server.
GC agent for GlassFish can be configured or disabled via the GlassFish admin panel in gfcluster-config > JVM Settings > JVM Options.