protected class IgniteCacheOffheapManagerImpl.CacheDataStoreImpl extends Object implements IgniteCacheOffheapManager.CacheDataStore
| Modifier and Type | Field and Description |
|---|---|
protected PartitionUpdateCounter |
pCntr
Update counter.
|
| Constructor and Description |
|---|
CacheDataStoreImpl(int partId,
String name,
CacheDataRowStore rowStore,
CacheDataTree dataTree) |
protected final PartitionUpdateCounter pCntr
public CacheDataStoreImpl(int partId,
String name,
CacheDataRowStore rowStore,
CacheDataTree dataTree)
partId - Partition number.name - Name.rowStore - Row store.dataTree - Data tree.public int partId()
partId in interface IgniteCacheOffheapManager.CacheDataStorepublic long cacheSize(int cacheId)
cacheSize in interface IgniteCacheOffheapManager.CacheDataStorecacheId - Cache ID.public Map<Integer,Long> cacheSizes()
cacheSizes in interface IgniteCacheOffheapManager.CacheDataStorepublic long fullSize()
fullSize in interface IgniteCacheOffheapManager.CacheDataStorepublic void updateSize(int cacheId,
long delta)
updateSize in interface IgniteCacheOffheapManager.CacheDataStorecacheId - Cache ID.delta - Size delta.public long nextUpdateCounter()
nextUpdateCounter in interface IgniteCacheOffheapManager.CacheDataStorepublic long initialUpdateCounter()
initialUpdateCounter in interface IgniteCacheOffheapManager.CacheDataStorepublic void updateInitialCounter(long cntr)
updateInitialCounter in interface IgniteCacheOffheapManager.CacheDataStorecntr - Counter.public long getAndIncrementUpdateCounter(long delta)
getAndIncrementUpdateCounter in interface IgniteCacheOffheapManager.CacheDataStoredelta - Delta.public long updateCounter()
updateCounter in interface IgniteCacheOffheapManager.CacheDataStorepublic void updateCounter(long val)
updateCounter in interface IgniteCacheOffheapManager.CacheDataStoreval - Update counter.public void updateCounter(long start,
long delta)
updateCounter in interface IgniteCacheOffheapManager.CacheDataStorestart - Start.delta - Deltapublic void finalizeUpdateCountres()
finalizeUpdateCountres in interface IgniteCacheOffheapManager.CacheDataStorepublic String name()
name in interface IgniteCacheOffheapManager.CacheDataStorepublic void invoke(GridCacheContext cctx, KeyCacheObject key, IgniteCacheOffheapManager.OffheapInvokeClosure c) throws IgniteCheckedException
invoke in interface IgniteCacheOffheapManager.CacheDataStorecctx - Cache context.key - Key.c - Closure.IgniteCheckedException - If failed.public CacheDataRow createRow(GridCacheContext cctx, KeyCacheObject key, CacheObject val, GridCacheVersion ver, long expireTime, @Nullable CacheDataRow oldRow) throws IgniteCheckedException
createRow in interface IgniteCacheOffheapManager.CacheDataStorecctx - Cache context.key - Key.val - Value.ver - Version.expireTime - Expire time.oldRow - Old row.IgniteCheckedException - If failed.public boolean mvccInitialValue(GridCacheContext cctx, KeyCacheObject key, @Nullable CacheObject val, GridCacheVersion ver, long expireTime, MvccVersion mvccVer, MvccVersion newMvccVer) throws IgniteCheckedException
mvccInitialValue in interface IgniteCacheOffheapManager.CacheDataStorecctx - Cache context.key - Key.val - Value.ver - Version.mvccVer - MVCC version.newMvccVer - New MVCC version.True if new value was inserted.IgniteCheckedException - If failed.public boolean mvccInitialValueIfAbsent(GridCacheContext cctx, KeyCacheObject key, @Nullable CacheObject val, GridCacheVersion ver, long expireTime, MvccVersion mvccVer, MvccVersion newMvccVer, byte txState, byte newTxState) throws IgniteCheckedException
mvccInitialValueIfAbsent in interface IgniteCacheOffheapManager.CacheDataStorecctx - Cache context.key - Key.val - Value.ver - Version.mvccVer - MVCC version.newMvccVer - New MVCC version.txState - Tx state hint for the mvcc version.newTxState - Tx state hint for the new mvcc version.True if new value was inserted.IgniteCheckedException - If failed.public boolean mvccUpdateRowWithPreloadInfo(GridCacheContext cctx, KeyCacheObject key, @Nullable CacheObject val, GridCacheVersion ver, long expireTime, MvccVersion mvccVer, MvccVersion newMvccVer, byte mvccTxState, byte newMvccTxState) throws IgniteCheckedException
mvccUpdateRowWithPreloadInfo in interface IgniteCacheOffheapManager.CacheDataStorecctx - Grid cache context.key - Key.val - Value.ver - Version.expireTime - Expiration time.mvccVer - Mvcc version.newMvccVer - New mvcc version.true on success.IgniteCheckedExceptionpublic MvccUpdateResult mvccUpdate(GridCacheContext cctx, KeyCacheObject key, CacheObject val, GridCacheVersion ver, long expireTime, MvccSnapshot mvccSnapshot, @Nullable CacheEntryPredicate filter, javax.cache.processor.EntryProcessor entryProc, Object[] invokeArgs, boolean primary, boolean needHistory, boolean noCreate, boolean needOldVal, boolean retVal) throws IgniteCheckedException
mvccUpdate in interface IgniteCacheOffheapManager.CacheDataStorecctx - Cache context.key - Key.val - Value.ver - Version.expireTime - Expire time.mvccSnapshot - MVCC snapshot.filter - Filter.entryProc - Entry processor.invokeArgs - Entry processor invoke arguments.primary - True if update is executed on primary node.needHistory - Flag to collect history.noCreate - Flag indicating that row should not be created if absent.needOldVal - True if need old value.retVal - Flag to return previous value.IgniteCheckedException - If failed.public MvccUpdateResult mvccRemove(GridCacheContext cctx, KeyCacheObject key, MvccSnapshot mvccSnapshot, @Nullable CacheEntryPredicate filter, boolean primary, boolean needHistory, boolean needOldVal, boolean retVal) throws IgniteCheckedException
mvccRemove in interface IgniteCacheOffheapManager.CacheDataStorecctx - Cache context.key - Key.mvccSnapshot - MVCC snapshot.filter - Filter.primary - True if update is executed on primary node.needHistory - Flag to collect history.needOldVal - True if need old value.retVal - Flag to return previous value.IgniteCheckedException - If failed.public MvccUpdateResult mvccLock(GridCacheContext cctx, KeyCacheObject key, MvccSnapshot mvccSnapshot) throws IgniteCheckedException
mvccLock in interface IgniteCacheOffheapManager.CacheDataStorecctx - Cache context.key - Key.mvccSnapshot - MVCC snapshot.IgniteCheckedException - If failed.public GridLongList mvccUpdateNative(GridCacheContext cctx, boolean primary, KeyCacheObject key, CacheObject val, GridCacheVersion ver, long expireTime, MvccSnapshot mvccSnapshot) throws IgniteCheckedException
mvccUpdateNative in interface IgniteCacheOffheapManager.CacheDataStorecctx - Cache context.primary - True if update is executed on primary node.key - Key.val - Value.ver - Version.expireTime - Expire time.mvccSnapshot - MVCC snapshot.IgniteCheckedException - If failed.public GridLongList mvccRemoveNative(GridCacheContext cctx, boolean primary, KeyCacheObject key, MvccSnapshot mvccSnapshot) throws IgniteCheckedException
mvccRemoveNative in interface IgniteCacheOffheapManager.CacheDataStorecctx - Cache context.primary - True if update is executed on primary node.key - Key.mvccSnapshot - MVCC snapshot.IgniteCheckedException - If failed.public void mvccRemoveAll(GridCacheContext cctx, KeyCacheObject key) throws IgniteCheckedException
mvccRemoveAll in interface IgniteCacheOffheapManager.CacheDataStorecctx - Cache context.key - Key.IgniteCheckedException - If failed.public int cleanup(GridCacheContext cctx, @Nullable List<MvccLinkAwareSearchRow> cleanupRows) throws IgniteCheckedException
cleanup in interface IgniteCacheOffheapManager.CacheDataStorecctx - Cache context.cleanupRows - Rows to cleanup.IgniteCheckedException - If failed.public void updateTxState(GridCacheContext cctx, CacheSearchRow row) throws IgniteCheckedException
updateTxState in interface IgniteCacheOffheapManager.CacheDataStorecctx - Cache context.row - Row.IgniteCheckedExceptionpublic void update(GridCacheContext cctx, KeyCacheObject key, CacheObject val, GridCacheVersion ver, long expireTime, @Nullable CacheDataRow oldRow) throws IgniteCheckedException
update in interface IgniteCacheOffheapManager.CacheDataStorecctx - Cache context.key - Key.val - Value.ver - Version.expireTime - Expire time.oldRow - Old row if available.IgniteCheckedException - If failed.public void mvccApplyUpdate(GridCacheContext cctx, KeyCacheObject key, CacheObject val, GridCacheVersion ver, long expireTime, MvccVersion mvccVer) throws IgniteCheckedException
mvccApplyUpdate in interface IgniteCacheOffheapManager.CacheDataStorecctx - Cache context.key - Key.val - Value.ver - Version.expireTime - Expire time.mvccVer - Mvcc version.IgniteCheckedExceptionpublic void remove(GridCacheContext cctx, KeyCacheObject key, int partId) throws IgniteCheckedException
remove in interface IgniteCacheOffheapManager.CacheDataStorecctx - Cache context.key - Key.partId - Partition number.IgniteCheckedException - If failed.public CacheDataRow find(GridCacheContext cctx, KeyCacheObject key) throws IgniteCheckedException
find in interface IgniteCacheOffheapManager.CacheDataStorecctx - Cache context.key - Key.IgniteCheckedException - If failed.public List<IgniteBiTuple<Object,MvccVersion>> mvccFindAllVersions(GridCacheContext cctx, KeyCacheObject key) throws IgniteCheckedException
mvccFindAllVersions in interface IgniteCacheOffheapManager.CacheDataStorecctx - Cache context.key - Key.IgniteCheckedException - If failed.public GridCursor<CacheDataRow> mvccAllVersionsCursor(GridCacheContext cctx, KeyCacheObject key, Object x) throws IgniteCheckedException
mvccAllVersionsCursor in interface IgniteCacheOffheapManager.CacheDataStorecctx - Cache context.key - Key.x - Implementation specific argument, null always means that we need to return full detached data row.IgniteCheckedException - If failed.public CacheDataRow mvccFind(GridCacheContext cctx, KeyCacheObject key, MvccSnapshot snapshot) throws IgniteCheckedException
mvccFind in interface IgniteCacheOffheapManager.CacheDataStorecctx - Cache context.key - Key.IgniteCheckedException - If failed.public GridCursor<? extends CacheDataRow> cursor() throws IgniteCheckedException
cursor in interface IgniteCacheOffheapManager.CacheDataStoreIgniteCheckedException - If failed.public GridCursor<? extends CacheDataRow> cursor(Object x) throws IgniteCheckedException
cursor in interface IgniteCacheOffheapManager.CacheDataStorex - Implementation specific argument, null always means that we need to return full detached data row.IgniteCheckedException - If failed.public GridCursor<? extends CacheDataRow> cursor(MvccSnapshot mvccSnapshot) throws IgniteCheckedException
cursor in interface IgniteCacheOffheapManager.CacheDataStoremvccSnapshot - MVCC snapshot.IgniteCheckedException - If failed.public GridCursor<? extends CacheDataRow> cursor(int cacheId) throws IgniteCheckedException
cursor in interface IgniteCacheOffheapManager.CacheDataStorecacheId - Cache ID.IgniteCheckedException - If failed.public GridCursor<? extends CacheDataRow> cursor(int cacheId, MvccSnapshot mvccSnapshot) throws IgniteCheckedException
cursor in interface IgniteCacheOffheapManager.CacheDataStorecacheId - Cache ID.mvccSnapshot - Mvcc snapshot.IgniteCheckedException - If failed.public GridCursor<? extends CacheDataRow> cursor(int cacheId, KeyCacheObject lower, KeyCacheObject upper) throws IgniteCheckedException
cursor in interface IgniteCacheOffheapManager.CacheDataStorecacheId - Cache ID.lower - Lower bound.upper - Upper bound.IgniteCheckedException - If failed.public GridCursor<? extends CacheDataRow> cursor(int cacheId, KeyCacheObject lower, KeyCacheObject upper, Object x) throws IgniteCheckedException
cursor in interface IgniteCacheOffheapManager.CacheDataStorecacheId - Cache ID.lower - Lower bound.upper - Upper bound.x - Implementation specific argument, null always means that we need to return full detached data row.IgniteCheckedException - If failed.public GridCursor<? extends CacheDataRow> cursor(int cacheId, KeyCacheObject lower, KeyCacheObject upper, Object x, MvccSnapshot snapshot) throws IgniteCheckedException
cursor in interface IgniteCacheOffheapManager.CacheDataStorecacheId - Cache ID.lower - Lower bound.upper - Upper bound.x - Implementation specific argument, null always means that we need to return full detached data row.snapshot - Mvcc snapshot.IgniteCheckedException - If failed.public void destroy()
throws IgniteCheckedException
destroy in interface IgniteCacheOffheapManager.CacheDataStoreIgniteCheckedException - If failed.public void clear(int cacheId)
throws IgniteCheckedException
clear in interface IgniteCacheOffheapManager.CacheDataStorecacheId - Cache ID.IgniteCheckedException - If failed.public RowStore rowStore()
rowStore in interface IgniteCacheOffheapManager.CacheDataStorepublic void setRowCacheCleaner(GridQueryRowCacheCleaner rowCacheCleaner)
setRowCacheCleaner in interface IgniteCacheOffheapManager.CacheDataStorerowCacheCleaner - Rows cache cleaner.public void init(long size,
long updCntr,
@Nullable
Map<Integer,Long> cacheSizes)
init in interface IgniteCacheOffheapManager.CacheDataStoresize - Size to init.updCntr - Update counter to init.cacheSizes - Cache sizes if store belongs to group containing multiple caches.public PendingEntriesTree pendingTree()
pendingTree in interface IgniteCacheOffheapManager.CacheDataStore
Follow @ApacheIgnite
Ignite Database and Caching Platform : ver. 2.7.5 Release Date : June 4 2019