ehcache

net.sf.ehcache.pool
Interface PoolableStore

All Superinterfaces:
Store
All Known Implementing Classes:
DiskStore, MemoryStore, NotifyingMemoryStore

public interface PoolableStore
extends Store

A poolable store reports its resource usage to a Pool.

Author:
Ludovic Orban

Field Summary
 
Fields inherited from interface net.sf.ehcache.store.Store
CLUSTER_COHERENT, NODE_COHERENT
 
Method Summary
 boolean evictFromOnDisk(int count, long size)
          Perform eviction to release on-disk resources
 boolean evictFromOnHeap(int count, long size)
          Perform eviction to release on-heap resources
 long getApproximateDiskByteSize()
          Return the approximate disk size in bytes
 long getApproximateDiskCountSize()
          Return the approximate disk size
 float getApproximateDiskHitRate()
          Return the approximate disk hit rate
 float getApproximateDiskMissRate()
          Return the approximate disk miss rate
 long getApproximateHeapByteSize()
          Return the approximate heap size in bytes
 long getApproximateHeapCountSize()
          Return the approximate heap size
 float getApproximateHeapHitRate()
          Return the approximate heap hit rate
 float getApproximateHeapMissRate()
          Return the approximate heap miss rate
 
Methods inherited from interface net.sf.ehcache.store.Store
addStoreListener, bufferFull, containsKey, containsKeyInMemory, containsKeyOffHeap, containsKeyOnDisk, dispose, executeQuery, expireElements, flush, get, getAll, getAllQuiet, getInMemoryEvictionPolicy, getInMemorySize, getInMemorySizeInBytes, getInternalContext, getKeys, getMBean, getOffHeapSize, getOffHeapSizeInBytes, getOnDiskSize, getOnDiskSizeInBytes, getQuiet, getSearchAttribute, getSize, getStatus, getTerracottaClusteredSize, hasAbortedSizeOf, isCacheCoherent, isClusterCoherent, isNodeCoherent, isPinned, put, putAll, putIfAbsent, putWithWriter, recalculateSize, remove, removeAll, removeAll, removeElement, removeStoreListener, removeWithWriter, replace, replace, setAttributeExtractors, setInMemoryEvictionPolicy, setNodeCoherent, setPinned, unpinAll, waitUntilClusterCoherent
 

Method Detail

evictFromOnHeap

boolean evictFromOnHeap(int count,
                        long size)
Perform eviction to release on-heap resources

Parameters:
count - the number of elements to evict
size - the size in bytes to free (hint)
Returns:
true if the requested number of elements could be evicted

evictFromOnDisk

boolean evictFromOnDisk(int count,
                        long size)
Perform eviction to release on-disk resources

Parameters:
count - the number of elements to evict
size - the size in bytes to free (hint)
Returns:
true if the requested number of elements could be evicted

getApproximateDiskHitRate

float getApproximateDiskHitRate()
Return the approximate disk hit rate

Returns:
the approximate disk hit rate

getApproximateDiskMissRate

float getApproximateDiskMissRate()
Return the approximate disk miss rate

Returns:
the approximate disk miss rate

getApproximateDiskCountSize

long getApproximateDiskCountSize()
Return the approximate disk size

Returns:
the approximate disk size

getApproximateDiskByteSize

long getApproximateDiskByteSize()
Return the approximate disk size in bytes

Returns:
the approximate disk size in bytes

getApproximateHeapHitRate

float getApproximateHeapHitRate()
Return the approximate heap hit rate

Returns:
the approximate heap hit rate

getApproximateHeapMissRate

float getApproximateHeapMissRate()
Return the approximate heap miss rate

Returns:
the approximate heap miss rate

getApproximateHeapCountSize

long getApproximateHeapCountSize()
Return the approximate heap size

Returns:
the approximate heap size

getApproximateHeapByteSize

long getApproximateHeapByteSize()
Return the approximate heap size in bytes

Returns:
the approximate heap size in bytes

ehcache

Copyright © 2003-2012 Terracotta, Inc.. All Rights Reserved.