|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.cassandra.cache.InstrumentingCache<K,V>
public class InstrumentingCache<K,V>
Wraps an ICache in requests + hits tracking.
Constructor Summary | |
---|---|
InstrumentingCache(ICache<K,V> map,
java.lang.String table,
java.lang.String name)
|
Method Summary | |
---|---|
void |
clear()
|
V |
get(K key)
|
int |
getCapacity()
|
long |
getHits()
total cache hit count since cache creation |
V |
getInternal(K key)
|
java.util.Set<K> |
getKeySet()
|
double |
getRecentHitRate()
hits / requests since the last time getHitRate was called. |
long |
getRequests()
total request count since cache creation |
int |
getSize()
|
java.util.Set<K> |
hotKeySet(int n)
|
boolean |
isCapacitySetManually()
|
boolean |
isPutCopying()
|
void |
put(K key,
V value)
|
void |
remove(K key)
|
void |
setCapacity(int capacity)
|
int |
size()
|
void |
updateCapacity(int capacity)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public InstrumentingCache(ICache<K,V> map, java.lang.String table, java.lang.String name)
Method Detail |
---|
public void put(K key, V value)
public V get(K key)
public V getInternal(K key)
public void remove(K key)
public int getCapacity()
getCapacity
in interface InstrumentingCacheMBean
public boolean isCapacitySetManually()
public void updateCapacity(int capacity)
public void setCapacity(int capacity)
setCapacity
in interface InstrumentingCacheMBean
public int size()
public int getSize()
getSize
in interface InstrumentingCacheMBean
public long getHits()
InstrumentingCacheMBean
getHits
in interface InstrumentingCacheMBean
public long getRequests()
InstrumentingCacheMBean
getRequests
in interface InstrumentingCacheMBean
public double getRecentHitRate()
InstrumentingCacheMBean
getRecentHitRate
in interface InstrumentingCacheMBean
public void clear()
public java.util.Set<K> getKeySet()
public java.util.Set<K> hotKeySet(int n)
public boolean isPutCopying()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |