Class FileCacheStatsProvider
- java.lang.Object
-
- com.sun.enterprise.v3.services.impl.monitor.stats.FileCacheStatsProvider
-
- All Implemented Interfaces:
StatsProvider
- Direct Known Subclasses:
FileCacheStatsProviderGlobal
@AMXMetadata(type="file-cache-mon", group="monitoring") @ManagedObject @Description("File Cache Statistics") public class FileCacheStatsProvider extends Object implements StatsProviderFile cache statistics- Author:
- Alexey Stashok
-
-
Field Summary
Fields Modifier and Type Field Description protected org.glassfish.external.statistics.impl.CountStatisticImplcontentHitsCountprotected org.glassfish.external.statistics.impl.CountStatisticImplcontentMissesCountprotected org.glassfish.grizzly.http.server.filecache.FileCachefileCacheprotected AtomicLongheapSizeprotected org.glassfish.external.statistics.impl.CountStatisticImplhitsCountprotected org.glassfish.external.statistics.impl.CountStatisticImplinfoHitsCountprotected org.glassfish.external.statistics.impl.CountStatisticImplinfoMissesCountprotected AtomicLongmappedMemorySizeprotected AtomicLongmaxHeapSizeprotected AtomicLongmaxMappedMemorySizeprotected org.glassfish.external.statistics.impl.CountStatisticImplmissesCountprotected org.glassfish.external.statistics.impl.CountStatisticImplopenCacheEntriesCount
-
Constructor Summary
Constructors Constructor Description FileCacheStatsProvider(String name)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddHeapSizeEvent(String fileCacheName, long size)voidaddMappedMemorySizeEvent(String fileCacheName, long size)voidcountContentHitEvent(String fileCacheName)voidcountContentMissEvent(String fileCacheName)voidcountHitEvent(String fileCacheName)voidcountInfoHitEvent(String fileCacheName)voidcountInfoMissEvent(String fileCacheName)voidcountMissEvent(String fileCacheName)voiddecOpenCacheEntriesEvent(String fileCacheName)org.glassfish.external.statistics.CountStatisticgetContentHitsCount()org.glassfish.external.statistics.CountStatisticgetContentMissesCount()org.glassfish.external.statistics.CountStatisticgetHeapSize()org.glassfish.external.statistics.CountStatisticgetHitsCount()org.glassfish.external.statistics.CountStatisticgetInfoHitsCount()org.glassfish.external.statistics.CountStatisticgetInfoMissesCount()org.glassfish.external.statistics.CountStatisticgetMappedMemorySize()org.glassfish.external.statistics.CountStatisticgetMaxHeapSize()org.glassfish.external.statistics.CountStatisticgetMaxMappedMemorySize()org.glassfish.external.statistics.CountStatisticgetMissesCount()org.glassfish.external.statistics.CountStatisticgetOpenCacheEntriesCount()ObjectgetStatsObject()Get object, from which StatsProvider can get statistics directly without listening emitting events.voidincOpenCacheEntriesEvent(String fileCacheName)voidsetStatsObject(Object object)Set object, from which StatsProvider can get statistics directly without listening emitting events.voidsubHeapSizeEvent(String fileCacheName, long size)voidsubMappedMemorySizeEvent(String fileCacheName, long size)
-
-
-
Field Detail
-
hitsCount
protected final org.glassfish.external.statistics.impl.CountStatisticImpl hitsCount
-
missesCount
protected final org.glassfish.external.statistics.impl.CountStatisticImpl missesCount
-
infoHitsCount
protected final org.glassfish.external.statistics.impl.CountStatisticImpl infoHitsCount
-
infoMissesCount
protected final org.glassfish.external.statistics.impl.CountStatisticImpl infoMissesCount
-
contentHitsCount
protected final org.glassfish.external.statistics.impl.CountStatisticImpl contentHitsCount
-
contentMissesCount
protected final org.glassfish.external.statistics.impl.CountStatisticImpl contentMissesCount
-
openCacheEntriesCount
protected final org.glassfish.external.statistics.impl.CountStatisticImpl openCacheEntriesCount
-
heapSize
protected final AtomicLong heapSize
-
mappedMemorySize
protected final AtomicLong mappedMemorySize
-
maxHeapSize
protected final AtomicLong maxHeapSize
-
maxMappedMemorySize
protected final AtomicLong maxMappedMemorySize
-
fileCache
protected volatile org.glassfish.grizzly.http.server.filecache.FileCache fileCache
-
-
Constructor Detail
-
FileCacheStatsProvider
public FileCacheStatsProvider(String name)
-
-
Method Detail
-
getStatsObject
public Object getStatsObject()
Description copied from interface:StatsProviderGet object, from which StatsProvider can get statistics directly without listening emitting events.- Specified by:
getStatsObjectin interfaceStatsProvider- Returns:
- statistics
-
setStatsObject
public void setStatsObject(Object object)
Description copied from interface:StatsProviderSet object, from which StatsProvider can get statistics directly without listening emitting events.- Specified by:
setStatsObjectin interfaceStatsProvider- Parameters:
object- statistics
-
getHitsCount
@ManagedAttribute(id="hits") @Description("Number of cache lookup hits") public org.glassfish.external.statistics.CountStatistic getHitsCount()
-
getMissesCount
@ManagedAttribute(id="misses") @Description("Number of cache lookup misses") public org.glassfish.external.statistics.CountStatistic getMissesCount()
-
getInfoHitsCount
@ManagedAttribute(id="infohits") @Description("Number of hits on cached file info") public org.glassfish.external.statistics.CountStatistic getInfoHitsCount()
-
getInfoMissesCount
@ManagedAttribute(id="infomisses") @Description("Number of misses on cached file info") public org.glassfish.external.statistics.CountStatistic getInfoMissesCount()
-
getContentHitsCount
@ManagedAttribute(id="contenthits") @Description("Number of hits on cached file content") public org.glassfish.external.statistics.CountStatistic getContentHitsCount()
-
getContentMissesCount
@ManagedAttribute(id="contentmisses") @Description("Number of misses on cached file content") public org.glassfish.external.statistics.CountStatistic getContentMissesCount()
-
getOpenCacheEntriesCount
@ManagedAttribute(id="opencacheentries") @Description("Number of current open cache entries") public org.glassfish.external.statistics.CountStatistic getOpenCacheEntriesCount()
-
getHeapSize
@ManagedAttribute(id="heapsize") @Description("Current cache size in bytes") public org.glassfish.external.statistics.CountStatistic getHeapSize()
-
getMaxHeapSize
@ManagedAttribute(id="maxheapsize") @Description("Maximum heap space used for cache") public org.glassfish.external.statistics.CountStatistic getMaxHeapSize()
-
getMappedMemorySize
@ManagedAttribute(id="mappedmemorysize") @Description("Size of mapped memory used for caching") public org.glassfish.external.statistics.CountStatistic getMappedMemorySize()
-
getMaxMappedMemorySize
@ManagedAttribute(id="maxmappedmemorysize") @Description("Maximum memory map size used for caching") public org.glassfish.external.statistics.CountStatistic getMaxMappedMemorySize()
-
countHitEvent
public void countHitEvent(String fileCacheName)
-
countMissEvent
public void countMissEvent(String fileCacheName)
-
countInfoHitEvent
public void countInfoHitEvent(String fileCacheName)
-
countInfoMissEvent
public void countInfoMissEvent(String fileCacheName)
-
countContentHitEvent
public void countContentHitEvent(String fileCacheName)
-
countContentMissEvent
public void countContentMissEvent(String fileCacheName)
-
incOpenCacheEntriesEvent
public void incOpenCacheEntriesEvent(String fileCacheName)
-
decOpenCacheEntriesEvent
public void decOpenCacheEntriesEvent(String fileCacheName)
-
addHeapSizeEvent
public void addHeapSizeEvent(String fileCacheName, long size)
-
subHeapSizeEvent
public void subHeapSizeEvent(String fileCacheName, long size)
-
addMappedMemorySizeEvent
public void addMappedMemorySizeEvent(String fileCacheName, long size)
-
subMappedMemorySizeEvent
public void subMappedMemorySizeEvent(String fileCacheName, long size)
-
-