Returns the number of times org.apache.jackrabbit.guava.common.cache.Cache lookup methods have returned either a cached or
uncached value. This is defined as getHitCount + getMissCount.
getHitCount
longgetHitCount()
Returns the number of times org.apache.jackrabbit.guava.common.cache.Cache lookup methods have returned a cached value.
getHitRate
doublegetHitRate()
Returns the ratio of cache requests which were hits. This is defined as
getHitCount / getRequestCount, or 1.0 when getRequestCount == 0.
Note that getHitRate + getMissRate =~ 1.0.
getMissCount
longgetMissCount()
Returns the number of times org.apache.jackrabbit.guava.common.cache.Cache lookup methods have returned an uncached (newly
loaded) value, or null. Multiple concurrent calls to org.apache.jackrabbit.guava.common.cache.Cache lookup methods on an absent
value can result in multiple misses, all returning the results of a single cache load
operation.
getMissRate
doublegetMissRate()
Returns the ratio of cache requests which were misses. This is defined as
getMissCount / getRequestCount, or 0.0 when getRequestCount == 0.
Note that getHitRate + getMissRate =~ 1.0. Cache misses include all requests which
weren't cache hits, including requests which resulted in either successful or failed loading
attempts, and requests which waited for other threads to finish loading. It is thus the case
that getMissCount >= getLoadSuccessCount + getLoadExceptionCount. Multiple
concurrent misses for the same key will result in a single load operation.
getLoadCount
longgetLoadCount()
Returns the total number of times that org.apache.jackrabbit.guava.common.cache.Cache lookup methods attempted to load new
values. This includes both successful load operations, as well as those that threw
exceptions. This is defined as getLoadSuccessCount + getLoadExceptionCount.
getLoadSuccessCount
longgetLoadSuccessCount()
Returns the number of times org.apache.jackrabbit.guava.common.cache.Cache lookup methods have successfully loaded a new value.
This is always incremented in conjunction with getMissCount(), though getMissCount
is also incremented when an exception is encountered during cache loading (see
getLoadExceptionCount()). Multiple concurrent misses for the same key will result in a
single load operation.
getLoadExceptionCount
longgetLoadExceptionCount()
Returns the number of times org.apache.jackrabbit.guava.common.cache.Cache lookup methods threw an exception while loading a
new value. This is always incremented in conjunction with getMissCount, though
getMissCount is also incremented when cache loading completes successfully (see
getLoadSuccessCount()). Multiple concurrent misses for the same key will result in a
single load operation.
getLoadExceptionRate
doublegetLoadExceptionRate()
Returns the ratio of cache loading attempts which threw exceptions. This is defined as
getLoadExceptionCount / (getLoadSuccessCount + getLoadExceptionCount), or
0.0 when getLoadSuccessCount + getLoadExceptionCount == 0.
getTotalLoadTime
longgetTotalLoadTime()
Returns the total number of nanoseconds the cache has spent loading new values. This can be
used to calculate the miss penalty. This value is increased every time
getLoadSuccessCount or getLoadExceptionCount is incremented.
getAverageLoadPenalty
doublegetAverageLoadPenalty()
Returns the average time spent loading new values. This is defined as
getTotalLoadTime / (getLoadSuccessCount + getLoadExceptionCount).
getEvictionCount
longgetEvictionCount()
Returns the number of times an entry has been evicted. This count does not include manual
org.apache.jackrabbit.guava.common.cache.Cache#invalidate invalidations.
getElementCount
longgetElementCount()
Get the number of elements/objects in the cache.
Returns:
the number of elements
getMaxTotalWeight
longgetMaxTotalWeight()
The maximum weight of entries the cache may contain.
Returns:
the maximum total weight of entries the cache may contain
estimateCurrentWeight
longestimateCurrentWeight()
Total weight of the complete cache. Depending on implementation it might be the amount
of RAM taken by the cache