public class GridCacheStoreManager<K,V> extends GridCacheManagerAdapter<K,V>
cctx, log| Constructor and Description |
|---|
GridCacheStoreManager(GridCacheStore<K,Object> store) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
configured() |
void |
forceFlush() |
boolean |
isLocalStore() |
boolean |
loadAllFromStore(GridCacheTx tx,
Collection<? extends K> keys,
GridBiInClosure<K,V> vis)
Loads data from persistent store.
|
boolean |
loadCache(GridInClosure3<K,V,GridCacheVersion> vis,
Object[] args)
Loads data from persistent store.
|
V |
loadFromStore(GridCacheTx tx,
K key)
Loads data from persistent store.
|
boolean |
putAllToStore(GridCacheTx tx,
Map<K,GridBiTuple<V,GridCacheVersion>> map)
Puts key-value pair into storage.
|
boolean |
putToStore(GridCacheTx tx,
K key,
V val,
GridCacheVersion ver)
Puts key-value pair into storage.
|
boolean |
removeAllFromStore(GridCacheTx tx,
Collection<? extends K> keys) |
boolean |
removeFromStore(GridCacheTx tx,
K key) |
protected void |
start0() |
protected void |
stop0(boolean cancel) |
GridCacheStore<K,Object> |
store() |
void |
txEnd(GridCacheTx tx,
boolean commit) |
context, kernalStartInfo, kernalStopInfo, log, onKernalStart, onKernalStart0, onKernalStop, onKernalStop0, printMemoryStats, start, startInfo, stop, stopInfo, toStringpublic GridCacheStoreManager(@Nullable GridCacheStore<K,Object> store)
store - Store.protected void start0()
throws GridException
start0 in class GridCacheManagerAdapter<K,V>GridException - If failed.protected void stop0(boolean cancel)
stop0 in class GridCacheManagerAdapter<K,V>cancel - Cancel flag.public boolean isLocalStore()
true If local store is configured.public boolean configured()
true If store configured.@Nullable public V loadFromStore(@Nullable GridCacheTx tx, K key) throws GridException
tx - Cache transaction.key - Cache key.GridException - If data loading failed.public boolean loadAllFromStore(@Nullable GridCacheTx tx, Collection<? extends K> keys, GridBiInClosure<K,V> vis) throws GridException
tx - Cache transaction.keys - Cache keys.vis - Closure.True if there is a persistent storage.GridException - If data loading failed.public boolean loadCache(GridInClosure3<K,V,GridCacheVersion> vis, Object[] args) throws GridException
vis - Closer to cache loaded elements.args - User arguments.True if there is a persistent storage.GridException - If data loading failed.public boolean putToStore(@Nullable GridCacheTx tx, K key, V val, GridCacheVersion ver) throws GridException
tx - Cache transaction.key - Key.val - Value.ver - Version.true If there is a persistent storage.GridException - If storage failed.public boolean putAllToStore(@Nullable GridCacheTx tx, Map<K,GridBiTuple<V,GridCacheVersion>> map) throws GridException
tx - Cache transaction.map - Map.True if there is a persistent storage.GridException - If storage failed.public boolean removeFromStore(@Nullable GridCacheTx tx, K key) throws GridException
tx - Cache transaction.key - Key.True if there is a persistent storage.GridException - If storage failed.public boolean removeAllFromStore(@Nullable GridCacheTx tx, Collection<? extends K> keys) throws GridException
tx - Cache transaction.keys - Key.True if there is a persistent storage.GridException - If storage failed.public GridCacheStore<K,Object> store()
public void forceFlush()
throws GridException
GridException - If failed.public void txEnd(GridCacheTx tx, boolean commit) throws GridException
tx - Transaction.commit - Commit.GridException - If failed.Copyright © 2014. All rights reserved.