@Override public boolean isDestroyed() { if (this.re.isDestroyedOrRemoved()) return true; return false; }
@Override public boolean isDestroyed() { if (this.re.isDestroyedOrRemoved()) return true; return false; }
@Override public boolean isDestroyedOrRemoved() { if (this.regionEntry != null) { return this.regionEntry.isDestroyedOrRemoved(); } assert this.rowLocation != null; return this.rowLocation.isDestroyedOrRemoved(); }
@Override public boolean isDestroyedOrRemoved() { return getRegionEntry().isDestroyedOrRemoved(); }
@Override public boolean isDestroyedOrRemoved() { if (this.regionEntry != null) { return this.regionEntry.isDestroyedOrRemoved(); } assert this.rowLocation != null; return this.rowLocation.isDestroyedOrRemoved(); }
@Override public boolean isDestroyedOrRemoved() { if (this.regionEntry != null) { return this.regionEntry.isDestroyedOrRemoved(); } assert this.rowLocation != null; return this.rowLocation.isDestroyedOrRemoved(); }
@Override public boolean isDestroyedOrRemoved() { return getRegionEntry().isDestroyedOrRemoved(); }
@Override public boolean isDestroyedOrRemoved() { return getRegionEntry().isDestroyedOrRemoved(); }
/** * Returns the tasks region entry if it "checks" out. The check is to * see if the region entry still exists. * @throws EntryNotFoundException if the task no longer has a region entry or * if the region entry it has is removed. */ protected RegionEntry getCheckedRegionEntry() throws EntryNotFoundException { RegionEntry result = this.re; if (re == null || re.isDestroyedOrRemoved()) { throw new EntryNotFoundException("expiration task no longer has access to region entry"); } return result; }
/** * Returns the tasks region entry if it "checks" out. The check is to * see if the region entry still exists. * @throws EntryNotFoundException if the task no longer has a region entry or * if the region entry it has is removed. */ protected RegionEntry getCheckedRegionEntry() throws EntryNotFoundException { RegionEntry result = this.re; if (re == null || re.isDestroyedOrRemoved()) { throw new EntryNotFoundException("expiration task no longer has access to region entry"); } return result; }
/** * Returns the entry's RegionEntry if it "checks" out. The check is to * see if the region entry still exists. * @throws EntryNotFoundException if the RegionEntry has been removed. */ private RegionEntry getCheckedRegionEntry() throws EntryNotFoundException { RegionEntry result = this.re; if (re.isDestroyedOrRemoved()) { throw new EntryNotFoundException("Entry for key " + re.getKey() + " no longer exists"); } return result; }
/** * Returns the entry's RegionEntry if it "checks" out. The check is to * see if the region entry still exists. * @throws EntryNotFoundException if the RegionEntry has been removed. */ private RegionEntry getCheckedRegionEntry() throws EntryNotFoundException { RegionEntry result = this.re; if (re.isDestroyedOrRemoved()) { throw new EntryNotFoundException("Entry for key " + re.getKey() + " no longer exists"); } return result; }
public final Object readEntry(final ExclusiveSharedLockObject lockObj, final Object context, int iContext, boolean allowTombstones) { final RegionEntry re = (RegionEntry)lockObj; if ((re.isTombstone() && allowTombstones) || !re.isDestroyedOrRemoved()) { return new EntrySnapshot(re, (LocalRegion)context, partitionedRegion, allowTombstones); } return null; } };
/** * Test Method: Fetch a value from the local cache * * @param key * The kye * @return the value associated with that key * @see LocalRegion#get(Object, Object, boolean, EntryEventImpl) */ public Object localCacheGet(Object key) { RegionEntry re = getRegionMap().getEntry(key); if (re == null || re.isDestroyedOrRemoved()) { // TODO:KIRK:OK if (re == null || Token.isRemoved(re.getValueInVM(this))) { return null; } else { return re.getValue(this); // OFFHEAP: spin until we can copy into a heap cd? } }
/** * Test Method: Fetch a value from the local cache * * @param key * The kye * @return the value associated with that key * @see LocalRegion#get(Object, Object, boolean, EntryEventImpl) */ public Object localCacheGet(Object key) { RegionEntry re = getRegionMap().getEntry(key); if (re == null || re.isDestroyedOrRemoved()) { // TODO:KIRK:OK if (re == null || Token.isRemoved(re.getValueInVM(this))) { return null; } else { return re.getValue(this); // OFFHEAP: spin until we can copy into a heap cd? } }
@Override public boolean isPending() { RegionEntry re = this.re; if(re == null) { return false; } if (re.isDestroyedOrRemoved()) { return false; } ExpirationAction action = getAction(); if (action == null) { return false; } if((action.isInvalidate() || action.isLocalInvalidate()) && re.isInvalid()) { return false; } return true; }
protected boolean nonTXContainsKey(KeyInfo keyInfo) { boolean contains = getRegionMap().containsKey(keyInfo.getKey()); if (contains && this.imageState.isClient()) { // fix for bug #40871 - concurrent RI causes containsKey for destroyed entry // to return true RegionEntry re = this.entries.getEntry(keyInfo.getKey()); // TODO:KIRK:OK if (re == null || Token.isRemoved(re.getValueInVM(this))) { if (re == null || re.isDestroyedOrRemoved()) { contains = false; } } return contains; }
@Override public Compensation generateUndo(Transaction xact, LimitObjectInput in) throws StandardException, IOException { // need to refresh the value since the underlying RegionEntry in the region // may have changed (causes #43889) final RegionEntry entry; if (this.row != null && (entry = this.row.getRegionEntry()).isDestroyedOrRemoved()) { this.row = Hash1IndexScanController.fetchRowLocation( entry.getKeyCopy(), this.memcontainer.getBaseContainer().getRegion()); } SortedMap2IndexInsertOperation undoOp = new SortedMap2IndexInsertOperation( this.memcontainer, this.key, this.row, this.isUnique); return undoOp; }
@Override public Compensation generateUndo(Transaction xact, LimitObjectInput in) throws StandardException, IOException { // need to refresh the value since the underlying RegionEntry in the region // may have changed (causes #43889) final RegionEntry entry; if (this.row != null && (entry = this.row.getRegionEntry()).isDestroyedOrRemoved()) { this.row = Hash1IndexScanController.fetchRowLocation( entry.getKeyCopy(), this.memcontainer.getBaseContainer().getRegion()); } SortedMap2IndexInsertOperation undoOp = new SortedMap2IndexInsertOperation( this.memcontainer, this.key, this.row, this.isUnique); return undoOp; }
@Override public Compensation generateUndo(Transaction xact, LimitObjectInput in) throws StandardException, IOException { // need to refresh the value since the underlying RegionEntry in the region // may have changed (causes #43889) final RegionEntry entry; if (this.row != null && (entry = this.row.getRegionEntry()).isDestroyedOrRemoved()) { this.row = Hash1IndexScanController.fetchRowLocation( entry.getKeyCopy(), this.memcontainer.getBaseContainer().getRegion()); } SortedMap2IndexInsertOperation undoOp = new SortedMap2IndexInsertOperation( this.memcontainer, this.key, this.row, this.isUnique); return undoOp; }