| Modifier and Type | Field and Description |
|---|---|
| public static final String | CLUSTER_COHERENT
clusterCoherent property |
| public static final String | NODE_COHERENT
nodeCoherent property |
| Modifier and Type | Method and Description |
|---|---|
| public void | |
| public boolean | Returns: true if the store write buffer is backed up.Some store types, such as the disk stores can fill their write buffers if puts come in too fast. |
| public boolean | Returns: true if found. No check is made to see if the Element is expired. 1.2The Element key key)A check to see if a key is in the Store. |
| public boolean | Returns: true if found. No check is made to see if the Element is expired.The Element key key)A check to see if a key is in the Store and is currently held in memory. |
| public boolean | Returns: true if found. No check is made to see if the Element is expired.The Element key key)A check to see if a key is in the Store and is currently held off-heap. |
| public boolean | Returns: true if found. No check is made to see if the Element is expired.The Element key key)A check to see if a key is in the Store and is currently held on disk. |
| public void | |
| public Results | Returns: query resultsquery to execute query)Execute the given query on this store |
| public void | |
| public void | |
| public Element | |
| public Map | Returns: a map of keys and their corresponding valuesa collection of keys to look for keys)Retries the elements associated with a set of keys and update the statistics Keys which are not present in the cache will have null values associated with them in the returned map |
| public Map | Returns: a map of keys and their corresponding valuesa collection of keys to look for keys)Retries the elements associated with a set of keys without updating the statistics Keys which are not present in the cache will have null values associated with them in the returned map |
| public Policy | Returns: the current eviction policy. This may not be the configured policy, if it has been dynamically set.
|
| public int | Returns: the count of the Elements in the Store and in-memory on the local machineReturns the current local in-memory store size |
| public long | Returns: the approximate in-memory size of the store in bytesGets the size of the in-memory portion of the store, in bytes. |
| public Object | Returns: some internal context (probably null)This should not be used, and will generally return null |
| public List | Returns: An List ofjava. keysGets an Array of the keys for all elements in the disk store. |
| public Object | Returns: implementation specific management beanOptional implementation specific MBean exposed by the store. |
| public int | Returns: the count of the Elements in the Store and off-heap on the local machineReturns the current local off-heap store size |
| public long | Returns: the approximate off-heap size of the store in bytesGets the size of the off-heap portion of the store, in bytes. |
| public int | Returns: the count of the Elements in the Store and on-disk on the local machineReturns the current local on-disk store size |
| public long | Returns: the on-disk size of the store in bytesGets the size of the on-disk portion of the store, in bytes. |
| public Element | |
| public < type of the attribute T> Attribute | Returns: the search attribute or null if non-existentthe name of the attribute to retrieve attributeName)Retrieve the given named search attribute |
| public Set | Returns: all search attributes known to this store at the time of invoking the method
|
| public int | Returns: the count of the Elements in the Store on the local machineReturns the current local store size |
| public Status | |
| public int | Returns: the count of the Elements in the Store across the clusterReturns the current Terracotta clustered store size |
| public boolean | Returns: true if at least one partially sized element may be in the cacheChecks if the cache may contain elements for which the SizeOf engine gave up and only partially calculated the size. |
| public boolean | Returns: true if the store is coherent; or false if the
store potentially splits the cache storage with another store or
isn't internally coherentIndicates whether this store provides a coherent view of all the elements in a cache. |
| public boolean | Returns: true if the cache is in coherent mode cluster-wide, false otherwiseReturns true if the cache is in coherent mode cluster-wide. |
| public boolean | Returns: true if the cache is in coherent mode cluster-wide, false otherwiseReturns true if the cache is in coherent mode for the current node. |
| public boolean | |
| public void | putAll(Collection<Element>
Collection of elements to be put in the store elements)Puts a collection of elements into the store. |
| public Element | Returns: the element previously cached for this key, or null if none.element to be added element)Put an element in the store if no element is currently mapped to the elements key. |
| public boolean | Returns: true if this is a new put for the key or element is null. Returns false if it was an update.Puts an item into the store and the cache writer manager in an atomic operation |
| public void | |
| public Element | |
| public void | |
| public void | |
| public Element | Returns: the Element removed or null if no Element was removedElement to be removed element, ElementValueComparator ElementValueComparator to use to compare elements comparator)Remove the Element mapped to the key for the supplied element if the value of the supplied Element is equal to the value of the cached Element. |
| public void | |
| public Element | removeWithWriter(Object key, CacheWriterManager writerManager)
Removes an item from the store and the cache writer manager in an atomic operation. |
| public boolean | Returns: true is the Element was replacedElement to be test against old, Element Element to be cached element, ElementValueComparator ElementValueComparator to use to compare elements comparator)Replace the cached element only if the value of the current Element is equal to the value of the supplied old Element. |
| public Element | |
| public void | setAttributeExtractors(Map<String, AttributeExtractor> extractors)
Inform this store of the configured attribute extractors. |
| public void | |
| public void | setNodeCoherent(boolean
true transitions to coherent mode, false to incoherent mode coherent)Sets the cache in coherent or incoherent mode for the current node depending on the parameter. |
| public void | waitUntilClusterCoherent()
This method waits until the cache is in coherent mode in all the connected nodes. |
| CLUSTER_COHERENT | back to summary |
|---|---|
| public static final String CLUSTER_COHERENT clusterCoherent property | |
| NODE_COHERENT | back to summary |
|---|---|
| public static final String NODE_COHERENT nodeCoherent property | |
| addStoreListener | back to summary |
|---|---|
| public void addStoreListener(StoreListener listener) Add a listener to the store. | |
| bufferFull | back to summary |
|---|---|
| public boolean bufferFull() Some store types, such as the disk stores can fill their write buffers if puts come in too fast. The thread will wait for a short time before checking again.
| |
| containsKey | back to summary |
|---|---|
| public boolean containsKey(Object key) A check to see if a key is in the Store.
| |
| containsKeyInMemory | back to summary |
|---|---|
| public boolean containsKeyInMemory(Object key) A check to see if a key is in the Store and is currently held in memory.
| |
| containsKeyOffHeap | back to summary |
|---|---|
| public boolean containsKeyOffHeap(Object key) A check to see if a key is in the Store and is currently held off-heap.
| |
| containsKeyOnDisk | back to summary |
|---|---|
| public boolean containsKeyOnDisk(Object key) A check to see if a key is in the Store and is currently held on disk.
| |
| dispose | back to summary |
|---|---|
| public void dispose() Prepares for shutdown. | |
| executeQuery | back to summary |
|---|---|
| public Results executeQuery(StoreQuery query) throws SearchException Execute the given query on this store
| |
| expireElements | back to summary |
|---|---|
| public void expireElements() Expire all elements. | |
| flush | back to summary |
|---|---|
| public void flush() throws IOException Flush elements to persistent store.
| |
| get | back to summary |
|---|---|
| public Element get(Object key) Gets an item from the cache. | |
| getAll | back to summary |
|---|---|
| public Map Retries the elements associated with a set of keys and update the statistics Keys which are not present in the cache will have null values associated with them in the returned map
| |
| getAllQuiet | back to summary |
|---|---|
| public Map Retries the elements associated with a set of keys without updating the statistics Keys which are not present in the cache will have null values associated with them in the returned map
| |
| getInMemoryEvictionPolicy | back to summary |
|---|---|
public Policy getInMemoryEvictionPolicy()
| |
| getInMemorySize | back to summary |
|---|---|
| public int getInMemorySize() Returns the current local in-memory store size
| |
| getInMemorySizeInBytes | back to summary |
|---|---|
| public long getInMemorySizeInBytes() Gets the size of the in-memory portion of the store, in bytes. This method may be expensive to run, depending on implementation. Implementers may choose to return an approximate size.
| |
| getInternalContext | back to summary |
|---|---|
| public Object getInternalContext() This should not be used, and will generally return null
| |
| getKeys | back to summary |
|---|---|
| public List Gets an Array of the keys for all elements in the disk store.
| |
| getMBean | back to summary |
|---|---|
| public Object getMBean() Optional implementation specific MBean exposed by the store.
| |
| getOffHeapSize | back to summary |
|---|---|
| public int getOffHeapSize() Returns the current local off-heap store size
| |
| getOffHeapSizeInBytes | back to summary |
|---|---|
| public long getOffHeapSizeInBytes() Gets the size of the off-heap portion of the store, in bytes.
| |
| getOnDiskSize | back to summary |
|---|---|
| public int getOnDiskSize() Returns the current local on-disk store size
| |
| getOnDiskSizeInBytes | back to summary |
|---|---|
| public long getOnDiskSizeInBytes() Gets the size of the on-disk portion of the store, in bytes.
| |
| getQuiet | back to summary |
|---|---|
| public Element getQuiet(Object key) Gets an
| |
| getSearchAttribute | back to summary |
|---|---|
| public <T> Attribute Retrieve the given named search attribute | |
| getSearchAttributes | back to summary |
|---|---|
| public Set | |
| getSize | back to summary |
|---|---|
| public int getSize() Returns the current local store size
| |
| getStatus | back to summary |
|---|---|
| public Status getStatus() Returns the cache status. | |
| getTerracottaClusteredSize | back to summary |
|---|---|
| public int getTerracottaClusteredSize() Returns the current Terracotta clustered store size
| |
| hasAbortedSizeOf | back to summary |
|---|---|
| public boolean hasAbortedSizeOf() Checks if the cache may contain elements for which the SizeOf engine gave up and only partially calculated the size.
| |
| isCacheCoherent | back to summary |
|---|---|
| public boolean isCacheCoherent() Indicates whether this store provides a coherent view of all the elements
in a cache.
Note that this is same as calling
| |
| isClusterCoherent | back to summary |
|---|---|
| public boolean isClusterCoherent() throws TerracottaNotRunningException Returns true if the cache is in coherent mode cluster-wide. Returns false otherwise. It applies to coherent clustering mechanisms only e.g. Terracotta
| |
| isNodeCoherent | back to summary |
|---|---|
| public boolean isNodeCoherent() throws TerracottaNotRunningException Returns true if the cache is in coherent mode for the current node. Returns false otherwise. It applies to coherent clustering mechanisms only e.g. Terracotta
| |
| put | back to summary |
|---|---|
| public boolean put(Element element) throws CacheException Puts an item into the store.
| |
| putAll | back to summary |
|---|---|
| public void putAll(Collection<Element> elements) throws CacheException Puts a collection of elements into the store.
| |
| putIfAbsent | back to summary |
|---|---|
| public Element putIfAbsent(Element element) throws NullPointerException Put an element in the store if no element is currently mapped to the elements key.
| |
| putWithWriter | back to summary |
|---|---|
| public boolean putWithWriter(Element element, CacheWriterManager writerManager) throws CacheException Puts an item into the store and the cache writer manager in an atomic operation
| |
| recalculateSize | back to summary |
|---|---|
| public void recalculateSize(Object key) Recalculate size of the element mapped to the key
| |
| remove | back to summary |
|---|---|
| public Element remove(Object key) Removes an item from the cache.
| |
| removeAll | back to summary |
|---|---|
| public void removeAll(Collection<?> keys) Removes a collection of elements from the cache. | |
| removeAll | back to summary |
|---|---|
| public void removeAll() throws CacheException Remove all of the elements from the store.
If there are registered | |
| removeElement | back to summary |
|---|---|
| public Element removeElement(Element element, ElementValueComparator comparator) throws NullPointerException Remove the Element mapped to the key for the supplied element if the value of the supplied Element is equal to the value of the cached Element. This is a CAS operation. It is consistent even against a distributed cache that is not coherent. If the old value is stale when this operation is attempted the remove does not take place.
| |
| removeStoreListener | back to summary |
|---|---|
| public void removeStoreListener(StoreListener listener) Remove listener from store. | |
| removeWithWriter | back to summary |
|---|---|
| public Element removeWithWriter(Object key, CacheWriterManager writerManager) throws CacheException Removes an item from the store and the cache writer manager in an atomic operation. | |
| replace | back to summary |
|---|---|
| public boolean replace(Element old, Element element, ElementValueComparator comparator) throws NullPointerException, IllegalArgumentException Replace the cached element only if the value of the current Element is equal to the value of the supplied old Element.
| |
| replace | back to summary |
|---|---|
| public Element replace(Element element) throws NullPointerException Replace the cached element only if an Element is currently cached for this key
| |
| setAttributeExtractors | back to summary |
|---|---|
| public void setAttributeExtractors(Map<String, AttributeExtractor> extractors) Inform this store of the configured attribute extractors. Stores that will not invoke extractors are free to ignore this call | |
| setInMemoryEvictionPolicy | back to summary |
|---|---|
| public void setInMemoryEvictionPolicy(Policy policy) Sets the eviction policy strategy. The Store will use a policy at startup. The store may allow changing the eviction policy strategy dynamically. Otherwise implementations will throw an exception if this method is called.
| |
| setNodeCoherent | back to summary |
|---|---|
| public void setNodeCoherent(boolean coherent) throws UnsupportedOperationException, TerracottaNotRunningException Sets the cache in coherent or incoherent mode for the current node depending on the parameter.
Calling It applies to coherent clustering mechanisms only e.g. Terracotta
| |
| waitUntilClusterCoherent | back to summary |
|---|---|
| public void waitUntilClusterCoherent() throws UnsupportedOperationException, TerracottaNotRunningException, InterruptedException This method waits until the cache is in coherent mode in all the connected nodes. If the cache is already in coherent mode it returns immediately It applies to coherent clustering mechanisms only e.g. Terracotta
| |