KB Article #179051
Monitoring ehCache usage
Problem
How can you monitor the gateway's use of ehCache?
Resolution
Monitoring ehCache requires that you enable JMX as described in KB # 163943, that you connect to JMX with jconsole, and that you enable the stats flag in ehCache programmatically. Until the stats flag is enabled, all the stats shown in jconsole will be zero. Because this has a performance impact, this is something that should only be done when needed.
Update for 7.7.x: Using policy and scripting filter to enable statistics is no longer needed.
There are two sample policies attached to this KB. The enable statistics policy will programmatically enable the cache flag in ehCache, allowing it to collect stats. The cacheSizes sample policy will simply print out all the cache sizes when invoked. If you have done everything correctly, you should see something like the following in jconsole:
