public class GridDhtDetachedCacheEntry extends GridDistributedCacheEntry
GridMetadataAwareAdapter.EntryKey
ATOMIC_VER_COMPARATOR, cctx, flags, key, log, logRef, startVer, val, ver
Constructor and Description |
---|
GridDhtDetachedCacheEntry(GridCacheContext ctx,
KeyCacheObject key,
int hash,
CacheObject val,
GridCacheMapEntry next,
int hdrId) |
Modifier and Type | Method and Description |
---|---|
boolean |
addRemoved(GridCacheVersion ver) |
boolean |
detached() |
protected void |
logUpdate(GridCacheOperation op,
CacheObject val,
GridCacheVersion writeVer,
long expireTime,
long updCntr) |
int |
partition() |
protected void |
removeValue()
Removes value from offheap.
|
void |
resetFromPrimary(CacheObject val,
GridCacheVersion ver)
Sets value to detached entry so it can be retrieved in transactional gets.
|
protected void |
storeValue(CacheObject val,
long expireTime,
GridCacheVersion ver,
CacheDataRow oldRow)
Stores value in offheap.
|
String |
toString() |
CacheDataRow |
unswap(boolean needVal,
boolean checkExpire)
Unswaps an entry.
|
protected void |
value(CacheObject val)
Sets entry value.
|
addLocal, addRemote, checkCallbacks, checkRemoved, checkThreadChain, doneRemote, readyLock, readyNearLock, recheck, remoteMvccSnapshot, removeExplicitNodeLocks, removeLock, removeLock, tmLock, txUnlock
candidate, candidate, checkObsolete, checkOwnerChanged, checkSerializableReadVersion, clear, clearReader, clearReaders, clearReserveForLoad, context, decrementMapPublicSize, deleted, deletedUnlocked, deletedUnlocked, equals, evictInternal, evictionDisabled, expireTime, expireTimeExtras, expireTimeUnlocked, hashCode, hasLockCandidate, hasLockCandidate, hasLockCandidateUnsafe, hasReaders, hasValue, hasValueUnlocked, incrementMapPublicSize, info, initialValue, innerGet, innerGetAndReserveForLoad, innerGetVersioned, innerReload, innerRemove, innerSet, innerUpdate, innerUpdateLocal, invalidate, invalidate, isDht, isInternal, isLocal, isNear, isNew, isNewLocked, isReplicated, isStartVersion, key, keyValue, localCandidate, localCandidates, localOwner, localPartition, lockedBy, lockedByAny, lockedByThread, lockedByThread, lockedByThread, lockedByThreadUnsafe, lockedByUnsafe, lockedLocally, lockedLocallyByIdOrThread, lockedLocallyUnsafe, markObsolete, markObsolete0, markObsoleteIfEmpty, markObsoleteVersion, memorySize, mvccAllLocal, mvccExtras, mvccExtras, nextPartCounter, obsolete, obsolete, obsoleteOrDeleted, obsoleteVersion, obsoleteVersionExtras, onInvalidate, onMarkedObsolete, onTtlExpired, onUnlock, onUpdateFinished, partitionValid, peek, peek, peekVisibleValue, rawExpireTime, rawGet, rawPut, rawTtl, readThrough, recordNodeId, startVersion, ttl, ttlAndExpireTimeExtras, ttlExtras, txKey, unswap, unswap, update, updateIndex, updateTtl, valid, valueBytes, valueBytes, valueBytes0, version, versionedEntry, versionedValue, visitable, wrap, wrapEviction, wrapLazyValue, wrapVersioned
addMeta, addMetaIfAbsent, addMetaIfAbsent, allMeta, clone, copyMeta, copyMeta, hasMeta, hasMeta, meta, putMetaIfAbsent, readExternalMeta, removeAllMeta, removeMeta, removeMeta, replaceMeta, writeExternalMeta
finalize, getClass, notify, notifyAll, wait, wait, wait
addMeta, hasMeta, meta, putMetaIfAbsent, removeMeta, removeMeta, replaceMeta
public GridDhtDetachedCacheEntry(GridCacheContext ctx, KeyCacheObject key, int hash, CacheObject val, GridCacheMapEntry next, int hdrId)
ctx
- Cache context.key
- Cache key.hash
- Key hash value.val
- Entry value.next
- Next entry in the linked list.hdrId
- Header ID.public void resetFromPrimary(CacheObject val, GridCacheVersion ver)
val
- Value.ver
- Version.@Nullable public CacheDataRow unswap(boolean needVal, boolean checkExpire) throws IgniteCheckedException
unswap
in class GridCacheMapEntry
needVal
- If false
then do not to deserialize value during unswap.checkExpire
- If true
checks for expiration, as result entry can be obsoleted or marked deleted.IgniteCheckedException
- If failed.protected void value(@Nullable CacheObject val)
value
in class GridCacheMapEntry
val
- Value to store.protected void storeValue(CacheObject val, long expireTime, GridCacheVersion ver, CacheDataRow oldRow) throws IgniteCheckedException
storeValue
in class GridCacheMapEntry
val
- Value.expireTime
- Expire time.ver
- New entry version.oldRow
- Old row if available.IgniteCheckedException
- If update failed.protected void logUpdate(GridCacheOperation op, CacheObject val, GridCacheVersion writeVer, long expireTime, long updCntr) throws IgniteCheckedException
logUpdate
in class GridCacheMapEntry
op
- Update operation.val
- Write value.writeVer
- Write version.expireTime
- Expire time.updCntr
- Update counter.IgniteCheckedException
protected void removeValue() throws IgniteCheckedException
removeValue
in class GridCacheMapEntry
IgniteCheckedException
- If failed.public boolean detached()
detached
in interface GridCacheEntryEx
detached
in class GridCacheMapEntry
False
if entry belongs to cache map, true
if this entry was created in colocated
cache and node is not primary for this key.public String toString()
toString
in class GridDistributedCacheEntry
public boolean addRemoved(GridCacheVersion ver)
addRemoved
in class GridDistributedCacheEntry
ver
- Lock version.True
if removed.public int partition()
partition
in interface GridCacheEntryEx
partition
in class GridCacheMapEntry
Follow @ApacheIgnite
Ignite Fabric : ver. 2.0.0 Release Date : April 30 2017