Package com.tangosol.net.partition
Class PartitionSplittingBackingMap.AggregatingCacheStatistics
- java.lang.Object
-
- com.tangosol.net.partition.PartitionSplittingBackingMap.AggregatingCacheStatistics
-
- All Implemented Interfaces:
CacheStatistics
- Enclosing class:
- PartitionSplittingBackingMap
public class PartitionSplittingBackingMap.AggregatingCacheStatistics extends Object implements CacheStatistics
An implementation of the CacheStatics interface that aggregates across the CacheStatics objects provided by each of the backing maps corresponding to the partitions managed by this PartitionSplittingBackingMap.
-
-
Constructor Summary
Constructors Constructor Description AggregatingCacheStatistics()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description doublegetAverageGetMillis()Determine the average number of milliseconds per get() invocation since the cache statistics were last reset.doublegetAverageHitMillis()Determine the average number of milliseconds per get() invocation that is a hit.doublegetAverageMissMillis()Determine the average number of milliseconds per get() invocation that is a miss.doublegetAveragePutMillis()Determine the average number of milliseconds per put() invocation since the cache statistics were last reset.longgetCacheHits()Determine the rough number of cache hits since the cache statistics were last reset.longgetCacheHitsMillis()Determine the total number of milliseconds (since the last statistics reset) for the get() operations for which an entry existed in this map.longgetCacheMisses()Determine the rough number of cache misses since the cache statistics were last reset.longgetCacheMissesMillis()Determine the total number of milliseconds (since the last statistics reset) for the get() operations for which no entry existed in this map.longgetCachePrunes()Determine the rough number of cache pruning cycles since the cache statistics were last reset.longgetCachePrunesMillis()Determine the total number of milliseconds (since the last statistics reset) spent on cache pruning.doublegetHitProbability()Determine the rough probability (0 <= p <= 1) that the next invocation will be a hit, based on the statistics collected since the last reset of the cache statistics.longgetTotalGets()Determine the total number of get() operations since the cache statistics were last reset.longgetTotalGetsMillis()Determine the total number of milliseconds spent on get() operations since the cache statistics were last reset.longgetTotalPuts()Determine the total number of put() operations since the cache statistics were last reset.longgetTotalPutsMillis()Determine the total number of milliseconds spent on put() operations since the cache statistics were last reset.voidresetHitStatistics()Reset all of the cache statistics.StringtoString()For debugging purposes, format the statistics information into a human-readable format.
-
-
-
Method Detail
-
getTotalGets
public long getTotalGets()
Determine the total number of get() operations since the cache statistics were last reset.- Specified by:
getTotalGetsin interfaceCacheStatistics- Returns:
- the total number of get() operations
-
getTotalGetsMillis
public long getTotalGetsMillis()
Determine the total number of milliseconds spent on get() operations since the cache statistics were last reset.- Specified by:
getTotalGetsMillisin interfaceCacheStatistics- Returns:
- the total number of milliseconds processing get() operations
-
getAverageGetMillis
public double getAverageGetMillis()
Determine the average number of milliseconds per get() invocation since the cache statistics were last reset.- Specified by:
getAverageGetMillisin interfaceCacheStatistics- Returns:
- the average number of milliseconds per get() operation
-
getTotalPuts
public long getTotalPuts()
Determine the total number of put() operations since the cache statistics were last reset.- Specified by:
getTotalPutsin interfaceCacheStatistics- Returns:
- the total number of put() operations
-
getTotalPutsMillis
public long getTotalPutsMillis()
Determine the total number of milliseconds spent on put() operations since the cache statistics were last reset.- Specified by:
getTotalPutsMillisin interfaceCacheStatistics- Returns:
- the total number of milliseconds processing put() operations
-
getAveragePutMillis
public double getAveragePutMillis()
Determine the average number of milliseconds per put() invocation since the cache statistics were last reset.- Specified by:
getAveragePutMillisin interfaceCacheStatistics- Returns:
- the average number of milliseconds per put() operation
-
getCacheHits
public long getCacheHits()
Determine the rough number of cache hits since the cache statistics were last reset.A cache hit is a read operation invocation (e.g. get()) for which an entry exists in this map.
- Specified by:
getCacheHitsin interfaceCacheStatistics- Returns:
- the number of get() calls that have been served by existing cache entries
-
getCacheHitsMillis
public long getCacheHitsMillis()
Determine the total number of milliseconds (since the last statistics reset) for the get() operations for which an entry existed in this map.- Specified by:
getCacheHitsMillisin interfaceCacheStatistics- Returns:
- the total number of milliseconds for the get() operations that were hits
-
getAverageHitMillis
public double getAverageHitMillis()
Determine the average number of milliseconds per get() invocation that is a hit.- Specified by:
getAverageHitMillisin interfaceCacheStatistics- Returns:
- the average number of milliseconds per cache hit
-
getCacheMisses
public long getCacheMisses()
Determine the rough number of cache misses since the cache statistics were last reset.A cache miss is a get() invocation that does not have an entry in this map.
- Specified by:
getCacheMissesin interfaceCacheStatistics- Returns:
- the number of get() calls that failed to find an existing cache entry because the requested key was not in the cache
-
getCacheMissesMillis
public long getCacheMissesMillis()
Determine the total number of milliseconds (since the last statistics reset) for the get() operations for which no entry existed in this map.- Specified by:
getCacheMissesMillisin interfaceCacheStatistics- Returns:
- the total number of milliseconds (since the last statistics reset) for the get() operations that were misses
-
getAverageMissMillis
public double getAverageMissMillis()
Determine the average number of milliseconds per get() invocation that is a miss.- Specified by:
getAverageMissMillisin interfaceCacheStatistics- Returns:
- the average number of milliseconds per cache miss
-
getHitProbability
public double getHitProbability()
Determine the rough probability (0 <= p <= 1) that the next invocation will be a hit, based on the statistics collected since the last reset of the cache statistics.- Specified by:
getHitProbabilityin interfaceCacheStatistics- Returns:
- the cache hit probability (0 <= p <= 1)
-
getCachePrunes
public long getCachePrunes()
Determine the rough number of cache pruning cycles since the cache statistics were last reset.For the LocalCache implementation, this refers to the number of times that the prune() method is executed.
- Specified by:
getCachePrunesin interfaceCacheStatistics- Returns:
- the total number of cache pruning cycles (since the last statistics reset)
-
getCachePrunesMillis
public long getCachePrunesMillis()
Determine the total number of milliseconds (since the last statistics reset) spent on cache pruning.For the LocalCache implementation, this refers to the time spent in the prune() method.
- Specified by:
getCachePrunesMillisin interfaceCacheStatistics- Returns:
- the total number of milliseconds (since the last statistics reset) for cache pruning operations
-
resetHitStatistics
public void resetHitStatistics()
Reset all of the cache statistics.Note that the method name implies that only the hit statistics are cleared, which is not the case; all of the statistics are cleared.
- Specified by:
resetHitStatisticsin interfaceCacheStatistics
-
-