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 StatsProvider
File cache statistics- Author:
- Alexey Stashok
-
-
Field Summary
Fields Modifier and Type Field Description protected org.glassfish.external.statistics.impl.CountStatisticImpl
contentHitsCount
protected org.glassfish.external.statistics.impl.CountStatisticImpl
contentMissesCount
protected org.glassfish.grizzly.http.server.filecache.FileCache
fileCache
protected AtomicLong
heapSize
protected org.glassfish.external.statistics.impl.CountStatisticImpl
hitsCount
protected org.glassfish.external.statistics.impl.CountStatisticImpl
infoHitsCount
protected org.glassfish.external.statistics.impl.CountStatisticImpl
infoMissesCount
protected AtomicLong
mappedMemorySize
protected AtomicLong
maxHeapSize
protected AtomicLong
maxMappedMemorySize
protected org.glassfish.external.statistics.impl.CountStatisticImpl
missesCount
protected org.glassfish.external.statistics.impl.CountStatisticImpl
openCacheEntriesCount
-
Constructor Summary
Constructors Constructor Description FileCacheStatsProvider(String name)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addHeapSizeEvent(String fileCacheName, long size)
void
addMappedMemorySizeEvent(String fileCacheName, long size)
void
countContentHitEvent(String fileCacheName)
void
countContentMissEvent(String fileCacheName)
void
countHitEvent(String fileCacheName)
void
countInfoHitEvent(String fileCacheName)
void
countInfoMissEvent(String fileCacheName)
void
countMissEvent(String fileCacheName)
void
decOpenCacheEntriesEvent(String fileCacheName)
org.glassfish.external.statistics.CountStatistic
getContentHitsCount()
org.glassfish.external.statistics.CountStatistic
getContentMissesCount()
org.glassfish.external.statistics.CountStatistic
getHeapSize()
org.glassfish.external.statistics.CountStatistic
getHitsCount()
org.glassfish.external.statistics.CountStatistic
getInfoHitsCount()
org.glassfish.external.statistics.CountStatistic
getInfoMissesCount()
org.glassfish.external.statistics.CountStatistic
getMappedMemorySize()
org.glassfish.external.statistics.CountStatistic
getMaxHeapSize()
org.glassfish.external.statistics.CountStatistic
getMaxMappedMemorySize()
org.glassfish.external.statistics.CountStatistic
getMissesCount()
org.glassfish.external.statistics.CountStatistic
getOpenCacheEntriesCount()
Object
getStatsObject()
Get object, from which StatsProvider can get statistics directly without listening emitting events.void
incOpenCacheEntriesEvent(String fileCacheName)
void
setStatsObject(Object object)
Set object, from which StatsProvider can get statistics directly without listening emitting events.void
subHeapSizeEvent(String fileCacheName, long size)
void
subMappedMemorySizeEvent(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:StatsProvider
Get object, from which StatsProvider can get statistics directly without listening emitting events.- Specified by:
getStatsObject
in interfaceStatsProvider
- Returns:
- statistics
-
setStatsObject
public void setStatsObject(Object object)
Description copied from interface:StatsProvider
Set object, from which StatsProvider can get statistics directly without listening emitting events.- Specified by:
setStatsObject
in 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)
-
-