System.out.printf("%-17s: %s%n", "Rack", probe.getRack());
// Exceptions
System.out.printf("%-17s: %s%n", "Exceptions", probe.getStorageMetric("Exceptions"));
CacheServiceMBean cacheService = probe.getCacheServiceMBean();
// Key Cache: Hits, Requests, RecentHitRate, SavePeriodInSeconds
System.out.printf("%-17s: entries %d, size %d (bytes), capacity %d (bytes), %d hits, %d requests, %.3f recent hit rate, %d save period in seconds%n",
"Key Cache",
probe.getCacheMetric("KeyCache", "Entries"),
probe.getCacheMetric("KeyCache", "Size"),
probe.getCacheMetric("KeyCache", "Capacity"),
probe.getCacheMetric("KeyCache", "Hits"),
probe.getCacheMetric("KeyCache", "Requests"),
probe.getCacheMetric("KeyCache", "HitRate"),
cacheService.getKeyCacheSavePeriodInSeconds());
// Row Cache: Hits, Requests, RecentHitRate, SavePeriodInSeconds
System.out.printf("%-17s: entries %d, size %d (bytes), capacity %d (bytes), %d hits, %d requests, %.3f recent hit rate, %d save period in seconds%n",
"Row Cache",
probe.getCacheMetric("RowCache", "Entries"),
probe.getCacheMetric("RowCache", "Size"),
probe.getCacheMetric("RowCache", "Capacity"),
probe.getCacheMetric("RowCache", "Hits"),
probe.getCacheMetric("RowCache", "Requests"),
probe.getCacheMetric("RowCache", "HitRate"),
cacheService.getRowCacheSavePeriodInSeconds());
// Counter Cache: Hits, Requests, RecentHitRate, SavePeriodInSeconds
System.out.printf("%-17s: entries %d, size %d (bytes), capacity %d (bytes), %d hits, %d requests, %.3f recent hit rate, %d save period in seconds%n",
"Counter Cache",
probe.getCacheMetric("CounterCache", "Entries"),
probe.getCacheMetric("CounterCache", "Size"),
probe.getCacheMetric("CounterCache", "Capacity"),
probe.getCacheMetric("CounterCache", "Hits"),
probe.getCacheMetric("CounterCache", "Requests"),
probe.getCacheMetric("CounterCache", "HitRate"),
cacheService.getCounterCacheSavePeriodInSeconds());
// Tokens
List<String> tokens = probe.getTokens();
if (tokens.size() == 1 || this.tokens)
for (String token : tokens)