@GridToStringExclude public class GridDhtAtomicCache<K,V> extends GridDhtCacheAdapter<K,V>
GridCacheAdapter.AsyncOp<T>, GridCacheAdapter.CacheExpiryPolicy, GridCacheAdapter.FutureHolder, GridCacheAdapter.TopologyVersionAwareJob, GridCacheAdapter.UpdateGetTimeStatClosure<T>, GridCacheAdapter.UpdatePutAndGetTimeStatClosure<T>, GridCacheAdapter.UpdatePutTimeStatClosure<T>, GridCacheAdapter.UpdateRemoveTimeStatClosure<T>, GridCacheAdapter.UpdateTimeStatClosure<T>preldrcacheCfg, CLEAR_ALL_SPLIT_THRESHOLD, ctx, keyCheck, lastFut, LOAD_CACHE_JOB_SINCE, LOAD_CACHE_JOB_V2_SINCE, locNodeId, log, map, MAX_RETRIES, metrics, RET2NULL, txLockMsgLog| Constructor and Description |
|---|
GridDhtAtomicCache()
Empty constructor required by
Externalizable. |
GridDhtAtomicCache(GridCacheContext<K,V> ctx) |
GridDhtAtomicCache(GridCacheContext<K,V> ctx,
GridCacheConcurrentMap map) |
| Modifier and Type | Method and Description |
|---|---|
protected void |
checkJta()
Checks if cache is working in JTA transaction and enlist cache as XAResource if necessary.
|
protected GridCacheMapEntryFactory |
entryFactory() |
protected V |
get0(K key,
String taskName,
boolean deserializeBinary,
boolean needVer) |
protected Map<K,V> |
getAll0(Collection<? extends K> keys,
boolean deserializeBinary,
boolean needVer) |
IgniteInternalFuture<Map<K,V>> |
getAllAsync(Collection<? extends K> keys,
boolean forcePrimary,
boolean skipTx,
UUID subjId,
String taskName,
boolean deserializeBinary,
boolean skipVals,
boolean canRemap,
boolean needVer)
This method is used internally.
|
protected V |
getAndPut0(K key,
V val,
CacheEntryPredicate filter) |
IgniteInternalFuture<V> |
getAndPutAsync0(K key,
V val,
CacheEntryPredicate filter) |
V |
getAndRemove0(K key) |
IgniteInternalFuture<V> |
getAndRemoveAsync0(K key) |
protected IgniteInternalFuture<V> |
getAsync(K key,
boolean forcePrimary,
boolean skipTx,
UUID subjId,
String taskName,
boolean deserializeBinary,
boolean skipVals,
boolean canRemap,
boolean needVer) |
protected void |
init()
Post constructor initialization for subclasses.
|
<T> javax.cache.processor.EntryProcessorResult<T> |
invoke(K key,
javax.cache.processor.EntryProcessor<K,V,T> entryProcessor,
Object... args) |
<T> Map<K,javax.cache.processor.EntryProcessorResult<T>> |
invokeAll(Map<? extends K,? extends javax.cache.processor.EntryProcessor<K,V,T>> map,
Object... args) |
<T> Map<K,javax.cache.processor.EntryProcessorResult<T>> |
invokeAll(Set<? extends K> keys,
javax.cache.processor.EntryProcessor<K,V,T> entryProcessor,
Object... args) |
<T> IgniteInternalFuture<Map<K,javax.cache.processor.EntryProcessorResult<T>>> |
invokeAllAsync(Map<? extends K,? extends javax.cache.processor.EntryProcessor<K,V,T>> map,
Object... args) |
<T> IgniteInternalFuture<Map<K,javax.cache.processor.EntryProcessorResult<T>>> |
invokeAllAsync(Set<? extends K> keys,
javax.cache.processor.EntryProcessor<K,V,T> entryProcessor,
Object... args) |
<T> IgniteInternalFuture<javax.cache.processor.EntryProcessorResult<T>> |
invokeAsync(K key,
javax.cache.processor.EntryProcessor<K,V,T> entryProcessor,
Object... args) |
boolean |
isDhtAtomic() |
boolean |
isFastMap(CacheEntryPredicate[] filters,
GridCacheOperation op)
Whether this is fast-map operation.
|
protected IgniteInternalFuture<Boolean> |
lockAllAsync(Collection<KeyCacheObject> keys,
long timeout,
IgniteTxLocalEx tx,
boolean isInvalidate,
boolean isRead,
boolean retval,
TransactionIsolation isolation,
long createTtl,
long accessTtl) |
GridNearCacheAdapter<K,V> |
near() |
void |
near(GridNearAtomicCache<K,V> near) |
protected boolean |
put0(K key,
V val,
CacheEntryPredicate filter) |
protected void |
putAll0(Map<? extends K,? extends V> m) |
IgniteInternalFuture<?> |
putAllAsync0(Map<? extends K,? extends V> m) |
void |
putAllConflict(Map<KeyCacheObject,GridCacheDrInfo> conflictMap)
Store DR data.
|
IgniteInternalFuture<?> |
putAllConflictAsync(Map<KeyCacheObject,GridCacheDrInfo> conflictMap)
Store DR data asynchronously.
|
IgniteInternalFuture<Boolean> |
putAsync0(K key,
V val,
CacheEntryPredicate filter) |
protected boolean |
remove0(K key,
CacheEntryPredicate filter) |
protected void |
removeAll0(Collection<? extends K> keys) |
IgniteInternalFuture<Object> |
removeAllAsync0(Collection<? extends K> keys) |
void |
removeAllConflict(Map<KeyCacheObject,GridCacheVersion> conflictMap)
Removes DR data.
|
IgniteInternalFuture<?> |
removeAllConflictAsync(Map<KeyCacheObject,GridCacheVersion> conflictMap)
Removes DR data asynchronously.
|
IgniteInternalFuture<Boolean> |
removeAsync0(K key,
CacheEntryPredicate filter) |
void |
start()
Starts this cache.
|
void |
stop()
Stops this cache.
|
String |
toString() |
V |
tryGetAndPut(K key,
V val)
Tries to get and put value in cache.
|
void |
updateAllAsyncInternal(UUID nodeId,
GridNearAtomicAbstractUpdateRequest req,
CI2<GridNearAtomicAbstractUpdateRequest,GridNearAtomicUpdateResponse> completionCb)
Executes local update.
|
beginMultiUpdate, createEntry, dhtPreloader, endMultiUpdate, entryEx, entryEx, entryExx, entryExx, entrySet, getDhtAsync, localEntriesIterator, localEntriesIterator, localLoad, localLoadCache, multiUpdateFinishFuture, multiUpdateTopologyFuture, needRemap, onDeferredDelete, onKernalStart, onKernalStop, onReconnected, peekExx, preloader, primarySize, primarySizeLong, printMemoryStats, processNearGetRequest, processNearGetResponse, processNearSingleGetRequest, processNearSingleGetResponse, sendTtlUpdateRequest, splitClearLocally, topology, unlockAlllockAllAsync, removeAll, removeAllAsync, removeVersionedEntry, txLockAsyncaffinity, allEntries, asyncOp, asyncOpAcquire, awaitLastFut, cache, clear, clear, clearAll, clearAllAsync, clearAsync, clearAsync, clearLocally, clearLocally, clearLocally, clearLocallyAll, clusterMetrics, clusterMetrics, clusterMxBean, commitTxAsync, configuration, containsKey, containsKeyAsync, containsKeys, containsKeysAsync, context, decrementSize, entries, entryEx, entryEx, entrySet, entrySet, entrySetx, evict, evictAll, expiry, expiryPolicy, forceKeyCheck, forSubjectId, get, get, getAll, getAllAsync, getAllAsync, getAllAsync, getAllAsync0, getAllOutTx, getAllOutTxAsync, getAndPut, getAndPut, getAndPutAsync, getAndPutAsync, getAndPutIfAbsent, getAndPutIfAbsentAsync, getAndRemove, getAndRemoveAsync, getAndReplace, getAndReplaceAsync, getAsync, getAsync, getEntries, getEntriesAsync, getEntry, getEntryAsync, getForcePrimary, getForcePrimaryAsync, getTopologySafe, igfsDataSpaceMax, igfsDataSpaceUsed, igniteIterator, igniteIterator, incrementSize, invoke, isColocated, isDht, isEmpty, isIgfsDataCache, isLocal, isLocked, isLockedByThread, isMongoDataCache, isMongoMetaCache, isNear, iterator, iterator, keepBinary, keySet, keySetx, loadAll, localEntries, localLoadCacheAsync, localMetrics, localMxBean, localPeek, localSize, localSizeLong, localSizeLong, lock, lockAll, lockAsync, log, map, metrics0, name, nearSize, offHeapAllocatedSize, offHeapEntriesCount, onIgfsDataSizeChanged, onUndeploy, overflowSize, peekEx, peekEx, primaryKeySet, promote, promoteAll, put, put, putAll, putAllAsync, putAsync, putAsync, putIfAbsent, putIfAbsentAsync, randomEntry, readExternal, readResolve, rebalance, remove, remove, remove, removeAll, removeAllAsync, removeAsync, removeAsync, removeAsync, removeEntry, removeIfObsolete, replace, replace, replaceAsync, replaceAsync, saveFuture, setSkipStore, size, size, sizeAsync, sizeLong, sizeLong, sizeLong, sizeLongAsync, sizeLongAsync, skipStore, startInfo, stopInfo, swapKeys, swapSize, tx, txStart, txStart, txStartEx, unlock, validateCacheKey, validateCacheKeys, values, values, withExpiryPolicy, withNoRetries, writeExternalpublic GridDhtAtomicCache()
Externalizable.public GridDhtAtomicCache(GridCacheContext<K,V> ctx)
ctx - Cache context.public GridDhtAtomicCache(GridCacheContext<K,V> ctx, GridCacheConcurrentMap map)
ctx - Cache context.map - Cache concurrent map.protected void checkJta()
throws IgniteCheckedException
checkJta in class GridCacheAdapter<K,V>IgniteCheckedException - In case of error.public boolean isDhtAtomic()
isDhtAtomic in class GridCacheAdapter<K,V>True if cache is DHT Atomic.protected GridCacheMapEntryFactory entryFactory()
entryFactory in class GridDhtCacheAdapter<K,V>protected void init()
init in class GridDhtCacheAdapter<K,V>public void start()
throws IgniteCheckedException
start in class GridDhtCacheAdapter<K,V>IgniteCheckedException - If start failed.public void stop()
stop in class GridDhtCacheAdapter<K,V>public void near(GridNearAtomicCache<K,V> near)
near - Near cache.public GridNearCacheAdapter<K,V> near()
near in class GridDhtCacheAdapter<K,V>protected V get0(K key, String taskName, boolean deserializeBinary, boolean needVer) throws IgniteCheckedException
get0 in class GridCacheAdapter<K,V>key - Key.taskName - Task name.deserializeBinary - Deserialize binary flag.needVer - Need version.IgniteCheckedException - If failed.protected IgniteInternalFuture<V> getAsync(K key, boolean forcePrimary, boolean skipTx, @Nullable UUID subjId, String taskName, boolean deserializeBinary, boolean skipVals, boolean canRemap, boolean needVer)
getAsync in class GridCacheAdapter<K,V>key - Key.forcePrimary - Force primary.skipTx - Skip tx.subjId - Subj Id.taskName - Task name.deserializeBinary - Deserialize binary.skipVals - Skip values.canRemap - Can remap flag.needVer - Need version.protected Map<K,V> getAll0(Collection<? extends K> keys, boolean deserializeBinary, boolean needVer) throws IgniteCheckedException
getAll0 in class GridCacheAdapter<K,V>keys - Keys.deserializeBinary - Deserialize binary flag.needVer - Need version.IgniteCheckedException - If read failed.public IgniteInternalFuture<Map<K,V>> getAllAsync(@Nullable Collection<? extends K> keys, boolean forcePrimary, boolean skipTx, @Nullable UUID subjId, String taskName, boolean deserializeBinary, boolean skipVals, boolean canRemap, boolean needVer)
GridDhtCacheAdapter.getDhtAsync(UUID, long, Map, boolean, AffinityTopologyVersion, UUID, int, IgniteCacheExpiryPolicy, boolean)
method instead to retrieve DHT value.getAllAsync in class GridDhtCacheAdapter<K,V>keys - Keys.forcePrimary - Force primary.skipTx - Skip tx.subjId - Subj Id.taskName - Task name.deserializeBinary - Deserialize binary.skipVals - Skip values.canRemap - Can remap flag.needVer - Need version.GridCacheAdapter.getAllAsync(Collection)protected V getAndPut0(K key, V val, @Nullable CacheEntryPredicate filter) throws IgniteCheckedException
getAndPut0 in class GridCacheAdapter<K,V>key - Key.val - Value.filter - Optional filter.IgniteCheckedException - If failed.protected boolean put0(K key, V val, CacheEntryPredicate filter) throws IgniteCheckedException
put0 in class GridCacheAdapter<K,V>key - Key.val - Value.filter - Filter.True if optional filter passed and value was stored in cache,
false otherwise. Note that this method will return true if filter is not
specified.IgniteCheckedException - If put operation failed.public IgniteInternalFuture<V> getAndPutAsync0(K key, V val, @Nullable CacheEntryPredicate filter)
getAndPutAsync0 in class GridCacheAdapter<K,V>key - Key.val - Value.filter - Optional filter.public IgniteInternalFuture<Boolean> putAsync0(K key, V val, @Nullable CacheEntryPredicate filter)
putAsync0 in class GridCacheAdapter<K,V>key - Key.val - Value.filter - Optional filter.public V tryGetAndPut(K key, V val) throws IgniteCheckedException
GridCacheTryPutFailedException
if topology exchange is in progress.tryGetAndPut in interface IgniteInternalCache<K,V>tryGetAndPut in class GridCacheAdapter<K,V>key - Key.val - value.IgniteCheckedException - In case of error.protected void putAll0(Map<? extends K,? extends V> m) throws IgniteCheckedException
putAll0 in class GridCacheAdapter<K,V>m - Map.IgniteCheckedException - If failed.public IgniteInternalFuture<?> putAllAsync0(Map<? extends K,? extends V> m)
putAllAsync0 in class GridCacheAdapter<K,V>m - Map.public void putAllConflict(Map<KeyCacheObject,GridCacheDrInfo> conflictMap) throws IgniteCheckedException
putAllConflict in interface IgniteInternalCache<K,V>putAllConflict in class GridCacheAdapter<K,V>conflictMap - DR map.IgniteCheckedException - If put operation failed.public IgniteInternalFuture<?> putAllConflictAsync(Map<KeyCacheObject,GridCacheDrInfo> conflictMap)
putAllConflictAsync in interface IgniteInternalCache<K,V>putAllConflictAsync in class GridCacheAdapter<K,V>conflictMap - DR map.public V getAndRemove0(K key) throws IgniteCheckedException
getAndRemove0 in class GridCacheAdapter<K,V>key - Key.IgniteCheckedException - If failed.public IgniteInternalFuture<V> getAndRemoveAsync0(K key)
getAndRemoveAsync0 in class GridCacheAdapter<K,V>key - Key.protected void removeAll0(Collection<? extends K> keys) throws IgniteCheckedException
removeAll0 in class GridCacheAdapter<K,V>keys - Keys.IgniteCheckedException - If failed.public IgniteInternalFuture<Object> removeAllAsync0(Collection<? extends K> keys)
removeAllAsync0 in class GridCacheAdapter<K,V>keys - Keys.protected boolean remove0(K key, CacheEntryPredicate filter) throws IgniteCheckedException
remove0 in class GridCacheAdapter<K,V>key - Key.filter - Filter.True if entry was removed.IgniteCheckedException - If failed.public IgniteInternalFuture<Boolean> removeAsync0(K key, @Nullable CacheEntryPredicate filter)
removeAsync0 in class GridCacheAdapter<K,V>key - Key.filter - Filter.public void removeAllConflict(Map<KeyCacheObject,GridCacheVersion> conflictMap) throws IgniteCheckedException
removeAllConflict in interface IgniteInternalCache<K,V>removeAllConflict in class GridCacheAdapter<K,V>conflictMap - DR map.IgniteCheckedException - If remove failed.public IgniteInternalFuture<?> removeAllConflictAsync(Map<KeyCacheObject,GridCacheVersion> conflictMap)
removeAllConflictAsync in interface IgniteInternalCache<K,V>removeAllConflictAsync in class GridCacheAdapter<K,V>conflictMap - DR map.protected IgniteInternalFuture<Boolean> lockAllAsync(Collection<KeyCacheObject> keys, long timeout, @Nullable IgniteTxLocalEx tx, boolean isInvalidate, boolean isRead, boolean retval, @Nullable TransactionIsolation isolation, long createTtl, long accessTtl)
lockAllAsync in class GridDistributedCacheAdapter<K,V>keys - Keys to lock.timeout - Timeout.tx - TransactionisInvalidate - Invalidation flag.isRead - Indicates whether value is read or written.retval - Flag to return value.isolation - Transaction isolation.createTtl - TTL for create operation.accessTtl - TTL for read operation.public <T> javax.cache.processor.EntryProcessorResult<T> invoke(K key, javax.cache.processor.EntryProcessor<K,V,T> entryProcessor, Object... args) throws IgniteCheckedException
invoke in interface IgniteInternalCache<K,V>invoke in class GridCacheAdapter<K,V>key - Key.entryProcessor - Entry processor.args - Arguments.IgniteCheckedException - If failed.public <T> Map<K,javax.cache.processor.EntryProcessorResult<T>> invokeAll(Set<? extends K> keys, javax.cache.processor.EntryProcessor<K,V,T> entryProcessor, Object... args) throws IgniteCheckedException
invokeAll in interface IgniteInternalCache<K,V>invokeAll in class GridCacheAdapter<K,V>keys - Keys.entryProcessor - Entry processor.args - Arguments.IgniteCheckedException - If failed.public <T> IgniteInternalFuture<javax.cache.processor.EntryProcessorResult<T>> invokeAsync(K key, javax.cache.processor.EntryProcessor<K,V,T> entryProcessor, Object... args)
invokeAsync in interface IgniteInternalCache<K,V>invokeAsync in class GridCacheAdapter<K,V>key - Key.entryProcessor - Entry processor.args - Arguments.public <T> IgniteInternalFuture<Map<K,javax.cache.processor.EntryProcessorResult<T>>> invokeAllAsync(Set<? extends K> keys, javax.cache.processor.EntryProcessor<K,V,T> entryProcessor, Object... args)
invokeAllAsync in interface IgniteInternalCache<K,V>invokeAllAsync in class GridCacheAdapter<K,V>keys - Keys.entryProcessor - Entry processor.args - Arguments.public <T> Map<K,javax.cache.processor.EntryProcessorResult<T>> invokeAll(Map<? extends K,? extends javax.cache.processor.EntryProcessor<K,V,T>> map, Object... args) throws IgniteCheckedException
invokeAll in interface IgniteInternalCache<K,V>invokeAll in class GridCacheAdapter<K,V>map - Map containing keys and entry processors to be applied to values.args - Arguments.IgniteCheckedException - If failed.public <T> IgniteInternalFuture<Map<K,javax.cache.processor.EntryProcessorResult<T>>> invokeAllAsync(Map<? extends K,? extends javax.cache.processor.EntryProcessor<K,V,T>> map, Object... args)
invokeAllAsync in interface IgniteInternalCache<K,V>invokeAllAsync in class GridCacheAdapter<K,V>map - Map containing keys and entry processors to be applied to values.args - Arguments.public boolean isFastMap(CacheEntryPredicate[] filters, GridCacheOperation op)
filters - Filters.op - Operation.True if fast-map.public void updateAllAsyncInternal(UUID nodeId, GridNearAtomicAbstractUpdateRequest req, CI2<GridNearAtomicAbstractUpdateRequest,GridNearAtomicUpdateResponse> completionCb)
nodeId - Node ID.req - Update request.completionCb - Completion callback.public String toString()
toString in class GridDhtCacheAdapter<K,V>
Follow @ApacheIgnite
Ignite Fabric : ver. 1.9.0 Release Date : March 2 2017