if (!alwaysFetchPosition && !de.isValueNull()) { return false; if (alwaysFetchPosition || de.isValueNull()) { if (did == null) { synchronized (de) {
/** * Testing purpose only * Get the value of an entry that is on disk without faulting * it in and without looking in the io buffer. * @since 3.2.1 */ static Object getValueOnDisk(DiskEntry entry, DiskRegion dr) { DiskId id = entry.getDiskId(); if (id == null) { return null; } dr.acquireReadLock(); try { synchronized (id) { if (id == null || (dr.isBackup() && id.getKeyId() == DiskRegion.INVALID_ID) || (!entry.isValueNull() && id.needsToBeWritten() && !EntryBits.isRecoveredFromDisk(id.getUserBits()))/*fix for bug 41942*/) { return null; } return dr.getNoBuffer(id); } } finally { dr.releaseReadLock(); } }
/** * Testing purpose only * Get the value of an entry that is on disk without faulting * it in and without looking in the io buffer. * @since 3.2.1 */ static Object getValueOnDisk(DiskEntry entry, DiskRegion dr) { DiskId id = entry.getDiskId(); if (id == null) { return null; } dr.acquireReadLock(); try { synchronized (id) { if ((dr.isBackup() && id.getKeyId() == DiskRegion.INVALID_ID) || (!entry.isValueNull() && id.needsToBeWritten() && !EntryBits.isRecoveredFromDisk(id.getUserBits()))/*fix for bug 41942*/) { return null; } return dr.getNoBuffer(id); } } finally { dr.releaseReadLock(); } }
/** * Get the serialized value directly from disk. Returned object may be * a {@link CachedDeserializable}. Goes straight to disk without faulting * into memory. Only looks at the disk storage, not at heap storage. * @param entry the entry used to identify the value to fetch * @param dr the persistent storage from which to fetch the value * @return either null, byte array, or CacheDeserializable * @since gemfire57_hotfix */ public static Object getSerializedValueOnDisk( DiskEntry entry, DiskRegion dr) { DiskId did = entry.getDiskId(); if (did == null) { return null; } dr.acquireReadLock(); try { synchronized (did) { if (did == null || (dr.isBackup() && did.getKeyId() == DiskRegion.INVALID_ID)) { return null; } else if (!entry.isValueNull() && did.needsToBeWritten() && !EntryBits.isRecoveredFromDisk(did.getUserBits())/*fix for bug 41942*/) { return null; } return dr.getSerializedData(did); } } finally { dr.releaseReadLock(); } }
/** * Get the serialized value directly from disk. Returned object may be * a {@link CachedDeserializable}. Goes straight to disk without faulting * into memory. Only looks at the disk storage, not at heap storage. * @param entry the entry used to identify the value to fetch * @param dr the persistent storage from which to fetch the value * @return either null, byte array, or CacheDeserializable * @since gemfire57_hotfix */ public static Object getSerializedValueOnDisk( DiskEntry entry, DiskRegion dr) { DiskId did = entry.getDiskId(); if (did == null) { return null; } dr.acquireReadLock(); try { synchronized (did) { if (did == null || (dr.isBackup() && did.getKeyId() == DiskRegion.INVALID_ID)) { return null; } else if (!entry.isValueNull() && did.needsToBeWritten() && !EntryBits.isRecoveredFromDisk(did.getUserBits())/*fix for bug 41942*/) { return null; } return dr.getSerializedData(did); } } finally { dr.releaseReadLock(); } }
if (de.isValueNull()) { if (did == null) { synchronized (de) {
public static void recoverValue(DiskEntry entry, long oplogId, DiskRecoveryStore recoveryStore, ByteArrayDataInput in) { boolean lruFaultedIn = false; synchronized (entry) { if (entry.isValueNull()) { DiskId did = entry.getDiskId(); if (did != null) {
boolean lruFaultedIn = false; synchronized (entry) { if (entry.isValueNull()) { DiskId did = entry.getDiskId(); if (did != null) {
|| (!entry.isValueNull() && did.needsToBeWritten() && !EntryBits.isRecoveredFromDisk(did.getUserBits()))/*fix for bug 41942*/) { return null;
boolean oldValueWasNull = entry.isValueNull();
|| (!entry.isValueNull() && did.needsToBeWritten() && !EntryBits.isRecoveredFromDisk(did.getUserBits()))/*fix for bug 41942*/) { return null;
boolean oldValueWasNull = entry.isValueNull(); int oldValueLength = did.getValueLength();
long oplogOffset = did.getOffsetInOplog(); boolean foundData = false; if (entry.isValueNull()) {
long oplogOffset = did.getOffsetInOplog(); boolean foundData = false; if (entry.isValueNull()) {
valueWasNull = entry.isValueNull(); entry._removePhase1(region);
valueWasNull = entry.isValueNull(); entry._removePhase1();
if (!entry.isValueNull()) { try { entry.handleValueOverflow(region);
if (!entry.isValueNull()) { try { entry.handleValueOverflow(region);