Is there an agentist way to get real-time statistics in the upcoming Spring 3.1?

Spring 3.1.0.M1 is missing, and one of many useful features is cache abstraction.

But what I could not find is an agent agent agnostic to show real-time statistics. Basically, I just want to show a list of all cache names and their corresponding keys with the number of hits, misses and their sizes (in kb) either on a web page or through JMX. I know that ehcache really provides this function, and if I use the ehcache API inside the code, I can get it (already used it in the past). But I believe that using the ehcache API inside the code eliminates the whole concept of spring frame cache abstraction.

+3
source share
1 answer

The only agnostic provider you have is the interface CacheManagerthat provides the following method:

Collection<String> getCacheNames() 

It returns a collection of caches known to the cache manager.

+5
source

All Articles