geode-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From kl...@apache.org
Subject [49/78] geode git commit: fixup
Date Tue, 16 May 2017 02:19:59 GMT
http://git-wip-us.apache.org/repos/asf/geode/blob/5adb681a/geode-core/src/main/java/org/apache/geode/internal/cache/VersionedThinDiskRegionEntryHeapUUIDKey.java
----------------------------------------------------------------------
diff --git a/geode-core/src/main/java/org/apache/geode/internal/cache/VersionedThinDiskRegionEntryHeapUUIDKey.java b/geode-core/src/main/java/org/apache/geode/internal/cache/VersionedThinDiskRegionEntryHeapUUIDKey.java
index ff8a624..bf9380c 100644
--- a/geode-core/src/main/java/org/apache/geode/internal/cache/VersionedThinDiskRegionEntryHeapUUIDKey.java
+++ b/geode-core/src/main/java/org/apache/geode/internal/cache/VersionedThinDiskRegionEntryHeapUUIDKey.java
@@ -20,17 +20,12 @@ package org.apache.geode.internal.cache;
 
 import java.util.UUID;
 
-
-
-
 import java.util.concurrent.atomic.AtomicLongFieldUpdater;
 
 import org.apache.geode.cache.EntryEvent;
 
-
 import org.apache.geode.internal.cache.lru.EnableLRU;
 
-
 import org.apache.geode.internal.cache.persistence.DiskRecoveryStore;
 
 import org.apache.geode.distributed.internal.membership.InternalDistributedMember;
@@ -38,12 +33,6 @@ import org.apache.geode.internal.cache.versions.VersionSource;
 import org.apache.geode.internal.cache.versions.VersionStamp;
 import org.apache.geode.internal.cache.versions.VersionTag;
 
-
-
-
-
-
-
 import org.apache.geode.internal.util.concurrent.CustomEntryConcurrentHashMap.HashEntry;
 
 // macros whose definition changes this class:
@@ -65,7 +54,7 @@ import org.apache.geode.internal.util.concurrent.CustomEntryConcurrentHashMap.Ha
  * ./dev-tools/generateRegionEntryClasses.sh (it must be run from the top level directory).
  */
 public class VersionedThinDiskRegionEntryHeapUUIDKey extends VersionedThinDiskRegionEntryHeap {
-  public VersionedThinDiskRegionEntryHeapUUIDKey  (RegionEntryContext context, UUID key, 
+  public VersionedThinDiskRegionEntryHeapUUIDKey(RegionEntryContext context, UUID key,
 
 
 
@@ -73,45 +62,43 @@ public class VersionedThinDiskRegionEntryHeapUUIDKey extends VersionedThinDiskRe
 
 
 
-      ) {
-    super(context, 
+  ) {
+    super(context,
 
-          (value instanceof RecoveredEntry ? null : value)
+        (value instanceof RecoveredEntry ? null : value)
 
 
 
-        );
+    );
     // DO NOT modify this class. It was generated from LeafRegionEntry.cpp
 
     initialize(context, value);
 
 
 
-
-
-
-
-
     this.keyMostSigBits = key.getMostSignificantBits();
     this.keyLeastSigBits = key.getLeastSignificantBits();
 
   }
 
   // DO NOT modify this class. It was generated from LeafRegionEntry.cpp
-  
+
   // common code
   protected int hash;
   private HashEntry<Object, Object> next;
   @SuppressWarnings("unused")
   private volatile long lastModified;
-  private static final AtomicLongFieldUpdater<VersionedThinDiskRegionEntryHeapUUIDKey> lastModifiedUpdater
-    = AtomicLongFieldUpdater.newUpdater(VersionedThinDiskRegionEntryHeapUUIDKey.class, "lastModified");
+  private static final AtomicLongFieldUpdater<VersionedThinDiskRegionEntryHeapUUIDKey> lastModifiedUpdater =
+      AtomicLongFieldUpdater.newUpdater(VersionedThinDiskRegionEntryHeapUUIDKey.class,
+          "lastModified");
 
   private volatile Object value;
+
   @Override
   protected Object getValueField() {
     return this.value;
   }
+
   @Override
   protected void setValueField(Object v) {
     this.value = v;
@@ -120,24 +107,29 @@ public class VersionedThinDiskRegionEntryHeapUUIDKey extends VersionedThinDiskRe
   protected long getLastModifiedField() {
     return lastModifiedUpdater.get(this);
   }
+
   protected boolean compareAndSetLastModifiedField(long expectedValue, long newValue) {
     return lastModifiedUpdater.compareAndSet(this, expectedValue, newValue);
   }
+
   /**
    * @see HashEntry#getEntryHash()
    */
   public int getEntryHash() {
     return this.hash;
   }
+
   protected void setEntryHash(int v) {
     this.hash = v;
   }
+
   /**
    * @see HashEntry#getNextEntry()
    */
   public HashEntry<Object, Object> getNextEntry() {
     return this.next;
   }
+
   /**
    * @see HashEntry#setNextEntry
    */
@@ -147,12 +139,13 @@ public class VersionedThinDiskRegionEntryHeapUUIDKey extends VersionedThinDiskRe
 
 
   // DO NOT modify this class. It was generated from LeafRegionEntry.cpp
-  
+
   // disk code
 
   protected void initialize(RegionEntryContext context, Object value) {
     diskInitialize(context, value);
   }
+
   @Override
   public int updateAsyncEntrySize(EnableLRU capacityController) {
     throw new IllegalStateException("should never be called");
@@ -160,12 +153,12 @@ public class VersionedThinDiskRegionEntryHeapUUIDKey extends VersionedThinDiskRe
 
 
   // DO NOT modify this class. It was generated from LeafRegionEntry.cpp
-  
+
   private void diskInitialize(RegionEntryContext context, Object value) {
-    DiskRecoveryStore drs = (DiskRecoveryStore)context;
+    DiskRecoveryStore drs = (DiskRecoveryStore) context;
     DiskStoreImpl ds = drs.getDiskStore();
     long maxOplogSize = ds.getMaxOplogSize();
-    //get appropriate instance of DiskId implementation based on maxOplogSize
+    // get appropriate instance of DiskId implementation based on maxOplogSize
     this.id = DiskId.createDiskId(maxOplogSize, true/* is persistence */, ds.needsLinkedList());
     Helper.initialize(this, drs, value);
   }
@@ -175,62 +168,60 @@ public class VersionedThinDiskRegionEntryHeapUUIDKey extends VersionedThinDiskRe
    * 
    * @since GemFire 5.1
    */
-  protected DiskId id;//= new DiskId();
+  protected DiskId id;// = new DiskId();
+
   public DiskId getDiskId() {
     return this.id;
   }
+
   @Override
   void setDiskId(RegionEntry old) {
-    this.id = ((AbstractDiskRegionEntry)old).getDiskId();
+    this.id = ((AbstractDiskRegionEntry) old).getDiskId();
   }
-//  // inlining DiskId
-//  // always have these fields
-//  /**
-//   * id consists of
-//   * most significant
-//   * 1 byte = users bits
-//   * 2-8 bytes = oplog id
-//   * least significant.
-//   * 
-//   * The highest bit in the oplog id part is set to 1 if the oplog id
-//   * is negative.
-//   * @todo this field could be an int for an overflow only region
-//   */
-//  private long id;
-//  /**
-//   * Length of the bytes on disk.
-//   * This is always set. If the value is invalid then it will be set to 0.
-//   * The most significant bit is used by overflow to mark it as needing to be written.
-//   */
-//  protected int valueLength = 0;
-//  // have intOffset or longOffset
-//  // intOffset
-//  /**
-//   * The position in the oplog (the oplog offset) where this entry's value is
-//   * stored
-//   */
-//  private volatile int offsetInOplog;
-//  // longOffset
-//  /**
-//   * The position in the oplog (the oplog offset) where this entry's value is
-//   * stored
-//   */
-//  private volatile long offsetInOplog;
-//  // have overflowOnly or persistence
-//  // overflowOnly
-//  // no fields
-//  // persistent
-//  /** unique entry identifier * */
-//  private long keyId;
-
-  
-
-
-
-  
+  // // inlining DiskId
+  // // always have these fields
+  // /**
+  // * id consists of
+  // * most significant
+  // * 1 byte = users bits
+  // * 2-8 bytes = oplog id
+  // * least significant.
+  // *
+  // * The highest bit in the oplog id part is set to 1 if the oplog id
+  // * is negative.
+  // * @todo this field could be an int for an overflow only region
+  // */
+  // private long id;
+  // /**
+  // * Length of the bytes on disk.
+  // * This is always set. If the value is invalid then it will be set to 0.
+  // * The most significant bit is used by overflow to mark it as needing to be written.
+  // */
+  // protected int valueLength = 0;
+  // // have intOffset or longOffset
+  // // intOffset
+  // /**
+  // * The position in the oplog (the oplog offset) where this entry's value is
+  // * stored
+  // */
+  // private volatile int offsetInOplog;
+  // // longOffset
+  // /**
+  // * The position in the oplog (the oplog offset) where this entry's value is
+  // * stored
+  // */
+  // private volatile long offsetInOplog;
+  // // have overflowOnly or persistence
+  // // overflowOnly
+  // // no fields
+  // // persistent
+  // /** unique entry identifier * */
+  // private long keyId;
+
+
 
   // DO NOT modify this class. It was generated from LeafRegionEntry.cpp
-  
+
   // versioned code
   private VersionSource memberID;
   private short entryVersionLowBytes;
@@ -242,16 +233,16 @@ public class VersionedThinDiskRegionEntryHeapUUIDKey extends VersionedThinDiskRe
   public int getEntryVersion() {
     return ((entryVersionHighByte << 16) & 0xFF0000) | (entryVersionLowBytes & 0xFFFF);
   }
-  
+
   public long getRegionVersion() {
-    return (((long)regionVersionHighBytes) << 32) | (regionVersionLowBytes & 0x00000000FFFFFFFFL);  
+    return (((long) regionVersionHighBytes) << 32) | (regionVersionLowBytes & 0x00000000FFFFFFFFL);
   }
-  
-  
+
+
   public long getVersionTimeStamp() {
     return getLastModified();
   }
-  
+
   public void setVersionTimeStamp(long time) {
     setLastModified(time);
   }
@@ -259,17 +250,18 @@ public class VersionedThinDiskRegionEntryHeapUUIDKey extends VersionedThinDiskRe
   public VersionSource getMemberID() {
     return this.memberID;
   }
+
   public int getDistributedSystemId() {
     return this.distributedSystemId;
   }
 
   // DO NOT modify this class. It was generated from LeafRegionEntry.cpp
-  
+
   public void setVersions(VersionTag tag) {
     this.memberID = tag.getMemberID();
     int eVersion = tag.getEntryVersion();
-    this.entryVersionLowBytes = (short)(eVersion & 0xffff);
-    this.entryVersionHighByte = (byte)((eVersion & 0xff0000) >> 16);
+    this.entryVersionLowBytes = (short) (eVersion & 0xffff);
+    this.entryVersionHighByte = (byte) ((eVersion & 0xff0000) >> 16);
     this.regionVersionHighBytes = tag.getRegionVersionHighBytes();
     this.regionVersionLowBytes = tag.getRegionVersionLowBytes();
     if (!(tag.isGatewayTag()) && this.distributedSystemId == tag.getDistributedSystemId()) {
@@ -281,11 +273,11 @@ public class VersionedThinDiskRegionEntryHeapUUIDKey extends VersionedThinDiskRe
     } else {
       setVersionTimeStamp(tag.getVersionTimeStamp());
     }
-    this.distributedSystemId = (byte)(tag.getDistributedSystemId() & 0xff);
+    this.distributedSystemId = (byte) (tag.getDistributedSystemId() & 0xff);
   }
 
   public void setMemberID(VersionSource memberID) {
-    this.memberID = memberID; 
+    this.memberID = memberID;
   }
 
   @Override
@@ -294,7 +286,7 @@ public class VersionedThinDiskRegionEntryHeapUUIDKey extends VersionedThinDiskRe
   }
 
   // DO NOT modify this class. It was generated from LeafRegionEntry.cpp
-  
+
   public VersionTag asVersionTag() {
     VersionTag tag = VersionTag.create(memberID);
     tag.setEntryVersion(getEntryVersion());
@@ -304,9 +296,9 @@ public class VersionedThinDiskRegionEntryHeapUUIDKey extends VersionedThinDiskRe
     return tag;
   }
 
-  public void processVersionTag(LocalRegion r, VersionTag tag,
-      boolean isTombstoneFromGII, boolean hasDelta,
-      VersionSource thisVM, InternalDistributedMember sender, boolean checkForConflicts) {
+  public void processVersionTag(LocalRegion r, VersionTag tag, boolean isTombstoneFromGII,
+      boolean hasDelta, VersionSource thisVM, InternalDistributedMember sender,
+      boolean checkForConflicts) {
     basicProcessVersionTag(r, tag, isTombstoneFromGII, hasDelta, thisVM, sender, checkForConflicts);
   }
 
@@ -321,23 +313,25 @@ public class VersionedThinDiskRegionEntryHeapUUIDKey extends VersionedThinDiskRe
   public short getRegionVersionHighBytes() {
     return this.regionVersionHighBytes;
   }
-  
+
   /** get rvv internal low bytes. Used by region entries for transferring to storage */
   public int getRegionVersionLowBytes() {
     return this.regionVersionLowBytes;
   }
 
-  
+
   // DO NOT modify this class. It was generated from LeafRegionEntry.cpp
-  
+
   // key code
 
   private final long keyMostSigBits;
   private final long keyLeastSigBits;
+
   @Override
   public Object getKey() {
     return new UUID(this.keyMostSigBits, this.keyLeastSigBits);
   }
+
   @Override
   public boolean isKeyEqual(Object k) {
     if (k instanceof UUID) {
@@ -347,7 +341,7 @@ public class VersionedThinDiskRegionEntryHeapUUIDKey extends VersionedThinDiskRe
     }
     return false;
   }
-  
+
 
   // DO NOT modify this class. It was generated from LeafRegionEntry.cpp
 }

http://git-wip-us.apache.org/repos/asf/geode/blob/5adb681a/geode-core/src/main/java/org/apache/geode/internal/cache/VersionedThinDiskRegionEntryOffHeapIntKey.java
----------------------------------------------------------------------
diff --git a/geode-core/src/main/java/org/apache/geode/internal/cache/VersionedThinDiskRegionEntryOffHeapIntKey.java b/geode-core/src/main/java/org/apache/geode/internal/cache/VersionedThinDiskRegionEntryOffHeapIntKey.java
index b7eaccc..cdfd226 100644
--- a/geode-core/src/main/java/org/apache/geode/internal/cache/VersionedThinDiskRegionEntryOffHeapIntKey.java
+++ b/geode-core/src/main/java/org/apache/geode/internal/cache/VersionedThinDiskRegionEntryOffHeapIntKey.java
@@ -18,19 +18,12 @@ package org.apache.geode.internal.cache;
 
 
 
-
-
-
-
-
 import java.util.concurrent.atomic.AtomicLongFieldUpdater;
 
 import org.apache.geode.cache.EntryEvent;
 
-
 import org.apache.geode.internal.cache.lru.EnableLRU;
 
-
 import org.apache.geode.internal.cache.persistence.DiskRecoveryStore;
 
 import org.apache.geode.distributed.internal.membership.InternalDistributedMember;
@@ -38,7 +31,6 @@ import org.apache.geode.internal.cache.versions.VersionSource;
 import org.apache.geode.internal.cache.versions.VersionStamp;
 import org.apache.geode.internal.cache.versions.VersionTag;
 
-
 import org.apache.geode.internal.offheap.OffHeapRegionEntryHelper;
 import org.apache.geode.internal.offheap.annotations.Released;
 import org.apache.geode.internal.offheap.annotations.Retained;
@@ -65,7 +57,7 @@ import org.apache.geode.internal.util.concurrent.CustomEntryConcurrentHashMap.Ha
  * ./dev-tools/generateRegionEntryClasses.sh (it must be run from the top level directory).
  */
 public class VersionedThinDiskRegionEntryOffHeapIntKey extends VersionedThinDiskRegionEntryOffHeap {
-  public VersionedThinDiskRegionEntryOffHeapIntKey  (RegionEntryContext context, int key, 
+  public VersionedThinDiskRegionEntryOffHeapIntKey(RegionEntryContext context, int key,
 
       @Retained
 
@@ -73,55 +65,59 @@ public class VersionedThinDiskRegionEntryOffHeapIntKey extends VersionedThinDisk
 
 
 
-      ) {
-    super(context, 
+  ) {
+    super(context,
 
-          (value instanceof RecoveredEntry ? null : value)
+        (value instanceof RecoveredEntry ? null : value)
 
 
 
-        );
+    );
     // DO NOT modify this class. It was generated from LeafRegionEntry.cpp
 
     initialize(context, value);
 
 
 
-
     this.key = key;
 
   }
 
   // DO NOT modify this class. It was generated from LeafRegionEntry.cpp
-  
+
   // common code
   protected int hash;
   private HashEntry<Object, Object> next;
   @SuppressWarnings("unused")
   private volatile long lastModified;
-  private static final AtomicLongFieldUpdater<VersionedThinDiskRegionEntryOffHeapIntKey> lastModifiedUpdater
-    = AtomicLongFieldUpdater.newUpdater(VersionedThinDiskRegionEntryOffHeapIntKey.class, "lastModified");
+  private static final AtomicLongFieldUpdater<VersionedThinDiskRegionEntryOffHeapIntKey> lastModifiedUpdater =
+      AtomicLongFieldUpdater.newUpdater(VersionedThinDiskRegionEntryOffHeapIntKey.class,
+          "lastModified");
 
   /**
    * All access done using ohAddrUpdater so it is used even though the compiler can not tell it is.
    */
   @SuppressWarnings("unused")
-  @Retained @Released private volatile long ohAddress;
+  @Retained
+  @Released
+  private volatile long ohAddress;
   /**
-   * I needed to add this because I wanted clear to call setValue which normally can only be called while the re is synced.
-   * But if I sync in that code it causes a lock ordering deadlock with the disk regions because they also get a rw lock in clear.
-   * Some hardware platforms do not support CAS on a long. If gemfire is run on one of those the AtomicLongFieldUpdater does a sync
-   * on the re and we will once again be deadlocked.
-   * I don't know if we support any of the hardware platforms that do not have a 64bit CAS. If we do then we can expect deadlocks
-   * on disk regions.
+   * I needed to add this because I wanted clear to call setValue which normally can only be called
+   * while the re is synced. But if I sync in that code it causes a lock ordering deadlock with the
+   * disk regions because they also get a rw lock in clear. Some hardware platforms do not support
+   * CAS on a long. If gemfire is run on one of those the AtomicLongFieldUpdater does a sync on the
+   * re and we will once again be deadlocked. I don't know if we support any of the hardware
+   * platforms that do not have a 64bit CAS. If we do then we can expect deadlocks on disk regions.
    */
-  private final static AtomicLongFieldUpdater<VersionedThinDiskRegionEntryOffHeapIntKey> ohAddrUpdater = AtomicLongFieldUpdater.newUpdater(VersionedThinDiskRegionEntryOffHeapIntKey.class, "ohAddress");
-  
+  private final static AtomicLongFieldUpdater<VersionedThinDiskRegionEntryOffHeapIntKey> ohAddrUpdater =
+      AtomicLongFieldUpdater.newUpdater(VersionedThinDiskRegionEntryOffHeapIntKey.class,
+          "ohAddress");
+
   @Override
   public Token getValueAsToken() {
     return OffHeapRegionEntryHelper.getValueAsToken(this);
   }
-  
+
   @Override
   protected Object getValueField() {
     return OffHeapRegionEntryHelper._getValue(this);
@@ -137,6 +133,7 @@ public class VersionedThinDiskRegionEntryOffHeapIntKey extends VersionedThinDisk
 
     OffHeapRegionEntryHelper.setValue(this, v);
   }
+
   @Override
 
   @Retained
@@ -154,7 +151,7 @@ public class VersionedThinDiskRegionEntryOffHeapIntKey extends VersionedThinDisk
   public boolean setAddress(long expectedAddr, long newAddr) {
     return ohAddrUpdater.compareAndSet(this, expectedAddr, newAddr);
   }
-  
+
   @Override
 
   @Released
@@ -162,36 +159,41 @@ public class VersionedThinDiskRegionEntryOffHeapIntKey extends VersionedThinDisk
   public void release() {
     OffHeapRegionEntryHelper.releaseEntry(this);
   }
-  
+
   @Override
   public void returnToPool() {
     // Deadcoded for now; never was working
-//    if (this instanceof VMThinRegionEntryLongKey) {
-//      factory.returnToPool((VMThinRegionEntryLongKey)this);
-//    }
+    // if (this instanceof VMThinRegionEntryLongKey) {
+    // factory.returnToPool((VMThinRegionEntryLongKey)this);
+    // }
   }
 
   protected long getLastModifiedField() {
     return lastModifiedUpdater.get(this);
   }
+
   protected boolean compareAndSetLastModifiedField(long expectedValue, long newValue) {
     return lastModifiedUpdater.compareAndSet(this, expectedValue, newValue);
   }
+
   /**
    * @see HashEntry#getEntryHash()
    */
   public int getEntryHash() {
     return this.hash;
   }
+
   protected void setEntryHash(int v) {
     this.hash = v;
   }
+
   /**
    * @see HashEntry#getNextEntry()
    */
   public HashEntry<Object, Object> getNextEntry() {
     return this.next;
   }
+
   /**
    * @see HashEntry#setNextEntry
    */
@@ -201,12 +203,13 @@ public class VersionedThinDiskRegionEntryOffHeapIntKey extends VersionedThinDisk
 
 
   // DO NOT modify this class. It was generated from LeafRegionEntry.cpp
-  
+
   // disk code
 
   protected void initialize(RegionEntryContext context, Object value) {
     diskInitialize(context, value);
   }
+
   @Override
   public int updateAsyncEntrySize(EnableLRU capacityController) {
     throw new IllegalStateException("should never be called");
@@ -214,12 +217,12 @@ public class VersionedThinDiskRegionEntryOffHeapIntKey extends VersionedThinDisk
 
 
   // DO NOT modify this class. It was generated from LeafRegionEntry.cpp
-  
+
   private void diskInitialize(RegionEntryContext context, Object value) {
-    DiskRecoveryStore drs = (DiskRecoveryStore)context;
+    DiskRecoveryStore drs = (DiskRecoveryStore) context;
     DiskStoreImpl ds = drs.getDiskStore();
     long maxOplogSize = ds.getMaxOplogSize();
-    //get appropriate instance of DiskId implementation based on maxOplogSize
+    // get appropriate instance of DiskId implementation based on maxOplogSize
     this.id = DiskId.createDiskId(maxOplogSize, true/* is persistence */, ds.needsLinkedList());
     Helper.initialize(this, drs, value);
   }
@@ -229,62 +232,60 @@ public class VersionedThinDiskRegionEntryOffHeapIntKey extends VersionedThinDisk
    * 
    * @since GemFire 5.1
    */
-  protected DiskId id;//= new DiskId();
+  protected DiskId id;// = new DiskId();
+
   public DiskId getDiskId() {
     return this.id;
   }
+
   @Override
   void setDiskId(RegionEntry old) {
-    this.id = ((AbstractDiskRegionEntry)old).getDiskId();
-  }
-//  // inlining DiskId
-//  // always have these fields
-//  /**
-//   * id consists of
-//   * most significant
-//   * 1 byte = users bits
-//   * 2-8 bytes = oplog id
-//   * least significant.
-//   * 
-//   * The highest bit in the oplog id part is set to 1 if the oplog id
-//   * is negative.
-//   * @todo this field could be an int for an overflow only region
-//   */
-//  private long id;
-//  /**
-//   * Length of the bytes on disk.
-//   * This is always set. If the value is invalid then it will be set to 0.
-//   * The most significant bit is used by overflow to mark it as needing to be written.
-//   */
-//  protected int valueLength = 0;
-//  // have intOffset or longOffset
-//  // intOffset
-//  /**
-//   * The position in the oplog (the oplog offset) where this entry's value is
-//   * stored
-//   */
-//  private volatile int offsetInOplog;
-//  // longOffset
-//  /**
-//   * The position in the oplog (the oplog offset) where this entry's value is
-//   * stored
-//   */
-//  private volatile long offsetInOplog;
-//  // have overflowOnly or persistence
-//  // overflowOnly
-//  // no fields
-//  // persistent
-//  /** unique entry identifier * */
-//  private long keyId;
-
-  
-
-
-
-  
+    this.id = ((AbstractDiskRegionEntry) old).getDiskId();
+  }
+  // // inlining DiskId
+  // // always have these fields
+  // /**
+  // * id consists of
+  // * most significant
+  // * 1 byte = users bits
+  // * 2-8 bytes = oplog id
+  // * least significant.
+  // *
+  // * The highest bit in the oplog id part is set to 1 if the oplog id
+  // * is negative.
+  // * @todo this field could be an int for an overflow only region
+  // */
+  // private long id;
+  // /**
+  // * Length of the bytes on disk.
+  // * This is always set. If the value is invalid then it will be set to 0.
+  // * The most significant bit is used by overflow to mark it as needing to be written.
+  // */
+  // protected int valueLength = 0;
+  // // have intOffset or longOffset
+  // // intOffset
+  // /**
+  // * The position in the oplog (the oplog offset) where this entry's value is
+  // * stored
+  // */
+  // private volatile int offsetInOplog;
+  // // longOffset
+  // /**
+  // * The position in the oplog (the oplog offset) where this entry's value is
+  // * stored
+  // */
+  // private volatile long offsetInOplog;
+  // // have overflowOnly or persistence
+  // // overflowOnly
+  // // no fields
+  // // persistent
+  // /** unique entry identifier * */
+  // private long keyId;
+
+
 
   // DO NOT modify this class. It was generated from LeafRegionEntry.cpp
-  
+
   // versioned code
   private VersionSource memberID;
   private short entryVersionLowBytes;
@@ -296,16 +297,16 @@ public class VersionedThinDiskRegionEntryOffHeapIntKey extends VersionedThinDisk
   public int getEntryVersion() {
     return ((entryVersionHighByte << 16) & 0xFF0000) | (entryVersionLowBytes & 0xFFFF);
   }
-  
+
   public long getRegionVersion() {
-    return (((long)regionVersionHighBytes) << 32) | (regionVersionLowBytes & 0x00000000FFFFFFFFL);  
+    return (((long) regionVersionHighBytes) << 32) | (regionVersionLowBytes & 0x00000000FFFFFFFFL);
   }
-  
-  
+
+
   public long getVersionTimeStamp() {
     return getLastModified();
   }
-  
+
   public void setVersionTimeStamp(long time) {
     setLastModified(time);
   }
@@ -313,17 +314,18 @@ public class VersionedThinDiskRegionEntryOffHeapIntKey extends VersionedThinDisk
   public VersionSource getMemberID() {
     return this.memberID;
   }
+
   public int getDistributedSystemId() {
     return this.distributedSystemId;
   }
 
   // DO NOT modify this class. It was generated from LeafRegionEntry.cpp
-  
+
   public void setVersions(VersionTag tag) {
     this.memberID = tag.getMemberID();
     int eVersion = tag.getEntryVersion();
-    this.entryVersionLowBytes = (short)(eVersion & 0xffff);
-    this.entryVersionHighByte = (byte)((eVersion & 0xff0000) >> 16);
+    this.entryVersionLowBytes = (short) (eVersion & 0xffff);
+    this.entryVersionHighByte = (byte) ((eVersion & 0xff0000) >> 16);
     this.regionVersionHighBytes = tag.getRegionVersionHighBytes();
     this.regionVersionLowBytes = tag.getRegionVersionLowBytes();
     if (!(tag.isGatewayTag()) && this.distributedSystemId == tag.getDistributedSystemId()) {
@@ -335,11 +337,11 @@ public class VersionedThinDiskRegionEntryOffHeapIntKey extends VersionedThinDisk
     } else {
       setVersionTimeStamp(tag.getVersionTimeStamp());
     }
-    this.distributedSystemId = (byte)(tag.getDistributedSystemId() & 0xff);
+    this.distributedSystemId = (byte) (tag.getDistributedSystemId() & 0xff);
   }
 
   public void setMemberID(VersionSource memberID) {
-    this.memberID = memberID; 
+    this.memberID = memberID;
   }
 
   @Override
@@ -348,7 +350,7 @@ public class VersionedThinDiskRegionEntryOffHeapIntKey extends VersionedThinDisk
   }
 
   // DO NOT modify this class. It was generated from LeafRegionEntry.cpp
-  
+
   public VersionTag asVersionTag() {
     VersionTag tag = VersionTag.create(memberID);
     tag.setEntryVersion(getEntryVersion());
@@ -358,9 +360,9 @@ public class VersionedThinDiskRegionEntryOffHeapIntKey extends VersionedThinDisk
     return tag;
   }
 
-  public void processVersionTag(LocalRegion r, VersionTag tag,
-      boolean isTombstoneFromGII, boolean hasDelta,
-      VersionSource thisVM, InternalDistributedMember sender, boolean checkForConflicts) {
+  public void processVersionTag(LocalRegion r, VersionTag tag, boolean isTombstoneFromGII,
+      boolean hasDelta, VersionSource thisVM, InternalDistributedMember sender,
+      boolean checkForConflicts) {
     basicProcessVersionTag(r, tag, isTombstoneFromGII, hasDelta, thisVM, sender, checkForConflicts);
   }
 
@@ -375,29 +377,26 @@ public class VersionedThinDiskRegionEntryOffHeapIntKey extends VersionedThinDisk
   public short getRegionVersionHighBytes() {
     return this.regionVersionHighBytes;
   }
-  
+
   /** get rvv internal low bytes. Used by region entries for transferring to storage */
   public int getRegionVersionLowBytes() {
     return this.regionVersionLowBytes;
   }
 
-  
-  // DO NOT modify this class. It was generated from LeafRegionEntry.cpp
-  
-  // key code
-
-
-
 
+  // DO NOT modify this class. It was generated from LeafRegionEntry.cpp
 
+  // key code
 
 
 
   private final int key;
+
   @Override
   public Object getKey() {
     return this.key;
   }
+
   @Override
   public boolean isKeyEqual(Object k) {
     if (k instanceof Integer) {
@@ -405,7 +404,7 @@ public class VersionedThinDiskRegionEntryOffHeapIntKey extends VersionedThinDisk
     }
     return false;
   }
-  
+
 
   // DO NOT modify this class. It was generated from LeafRegionEntry.cpp
 }

http://git-wip-us.apache.org/repos/asf/geode/blob/5adb681a/geode-core/src/main/java/org/apache/geode/internal/cache/VersionedThinDiskRegionEntryOffHeapLongKey.java
----------------------------------------------------------------------
diff --git a/geode-core/src/main/java/org/apache/geode/internal/cache/VersionedThinDiskRegionEntryOffHeapLongKey.java b/geode-core/src/main/java/org/apache/geode/internal/cache/VersionedThinDiskRegionEntryOffHeapLongKey.java
index b1c31ed..7ef2d5f 100644
--- a/geode-core/src/main/java/org/apache/geode/internal/cache/VersionedThinDiskRegionEntryOffHeapLongKey.java
+++ b/geode-core/src/main/java/org/apache/geode/internal/cache/VersionedThinDiskRegionEntryOffHeapLongKey.java
@@ -18,19 +18,12 @@ package org.apache.geode.internal.cache;
 
 
 
-
-
-
-
-
 import java.util.concurrent.atomic.AtomicLongFieldUpdater;
 
 import org.apache.geode.cache.EntryEvent;
 
-
 import org.apache.geode.internal.cache.lru.EnableLRU;
 
-
 import org.apache.geode.internal.cache.persistence.DiskRecoveryStore;
 
 import org.apache.geode.distributed.internal.membership.InternalDistributedMember;
@@ -38,7 +31,6 @@ import org.apache.geode.internal.cache.versions.VersionSource;
 import org.apache.geode.internal.cache.versions.VersionStamp;
 import org.apache.geode.internal.cache.versions.VersionTag;
 
-
 import org.apache.geode.internal.offheap.OffHeapRegionEntryHelper;
 import org.apache.geode.internal.offheap.annotations.Released;
 import org.apache.geode.internal.offheap.annotations.Retained;
@@ -64,8 +56,9 @@ import org.apache.geode.internal.util.concurrent.CustomEntryConcurrentHashMap.Ha
  * Do not modify this class. It was generated. Instead modify LeafRegionEntry.cpp and then run
  * ./dev-tools/generateRegionEntryClasses.sh (it must be run from the top level directory).
  */
-public class VersionedThinDiskRegionEntryOffHeapLongKey extends VersionedThinDiskRegionEntryOffHeap {
-  public VersionedThinDiskRegionEntryOffHeapLongKey  (RegionEntryContext context, long key, 
+public class VersionedThinDiskRegionEntryOffHeapLongKey
+    extends VersionedThinDiskRegionEntryOffHeap {
+  public VersionedThinDiskRegionEntryOffHeapLongKey(RegionEntryContext context, long key,
 
       @Retained
 
@@ -73,57 +66,59 @@ public class VersionedThinDiskRegionEntryOffHeapLongKey extends VersionedThinDis
 
 
 
-      ) {
-    super(context, 
+  ) {
+    super(context,
 
-          (value instanceof RecoveredEntry ? null : value)
+        (value instanceof RecoveredEntry ? null : value)
 
 
 
-        );
+    );
     // DO NOT modify this class. It was generated from LeafRegionEntry.cpp
 
     initialize(context, value);
 
 
 
-
-
-
     this.key = key;
 
   }
 
   // DO NOT modify this class. It was generated from LeafRegionEntry.cpp
-  
+
   // common code
   protected int hash;
   private HashEntry<Object, Object> next;
   @SuppressWarnings("unused")
   private volatile long lastModified;
-  private static final AtomicLongFieldUpdater<VersionedThinDiskRegionEntryOffHeapLongKey> lastModifiedUpdater
-    = AtomicLongFieldUpdater.newUpdater(VersionedThinDiskRegionEntryOffHeapLongKey.class, "lastModified");
+  private static final AtomicLongFieldUpdater<VersionedThinDiskRegionEntryOffHeapLongKey> lastModifiedUpdater =
+      AtomicLongFieldUpdater.newUpdater(VersionedThinDiskRegionEntryOffHeapLongKey.class,
+          "lastModified");
 
   /**
    * All access done using ohAddrUpdater so it is used even though the compiler can not tell it is.
    */
   @SuppressWarnings("unused")
-  @Retained @Released private volatile long ohAddress;
+  @Retained
+  @Released
+  private volatile long ohAddress;
   /**
-   * I needed to add this because I wanted clear to call setValue which normally can only be called while the re is synced.
-   * But if I sync in that code it causes a lock ordering deadlock with the disk regions because they also get a rw lock in clear.
-   * Some hardware platforms do not support CAS on a long. If gemfire is run on one of those the AtomicLongFieldUpdater does a sync
-   * on the re and we will once again be deadlocked.
-   * I don't know if we support any of the hardware platforms that do not have a 64bit CAS. If we do then we can expect deadlocks
-   * on disk regions.
+   * I needed to add this because I wanted clear to call setValue which normally can only be called
+   * while the re is synced. But if I sync in that code it causes a lock ordering deadlock with the
+   * disk regions because they also get a rw lock in clear. Some hardware platforms do not support
+   * CAS on a long. If gemfire is run on one of those the AtomicLongFieldUpdater does a sync on the
+   * re and we will once again be deadlocked. I don't know if we support any of the hardware
+   * platforms that do not have a 64bit CAS. If we do then we can expect deadlocks on disk regions.
    */
-  private final static AtomicLongFieldUpdater<VersionedThinDiskRegionEntryOffHeapLongKey> ohAddrUpdater = AtomicLongFieldUpdater.newUpdater(VersionedThinDiskRegionEntryOffHeapLongKey.class, "ohAddress");
-  
+  private final static AtomicLongFieldUpdater<VersionedThinDiskRegionEntryOffHeapLongKey> ohAddrUpdater =
+      AtomicLongFieldUpdater.newUpdater(VersionedThinDiskRegionEntryOffHeapLongKey.class,
+          "ohAddress");
+
   @Override
   public Token getValueAsToken() {
     return OffHeapRegionEntryHelper.getValueAsToken(this);
   }
-  
+
   @Override
   protected Object getValueField() {
     return OffHeapRegionEntryHelper._getValue(this);
@@ -139,6 +134,7 @@ public class VersionedThinDiskRegionEntryOffHeapLongKey extends VersionedThinDis
 
     OffHeapRegionEntryHelper.setValue(this, v);
   }
+
   @Override
 
   @Retained
@@ -156,7 +152,7 @@ public class VersionedThinDiskRegionEntryOffHeapLongKey extends VersionedThinDis
   public boolean setAddress(long expectedAddr, long newAddr) {
     return ohAddrUpdater.compareAndSet(this, expectedAddr, newAddr);
   }
-  
+
   @Override
 
   @Released
@@ -164,36 +160,41 @@ public class VersionedThinDiskRegionEntryOffHeapLongKey extends VersionedThinDis
   public void release() {
     OffHeapRegionEntryHelper.releaseEntry(this);
   }
-  
+
   @Override
   public void returnToPool() {
     // Deadcoded for now; never was working
-//    if (this instanceof VMThinRegionEntryLongKey) {
-//      factory.returnToPool((VMThinRegionEntryLongKey)this);
-//    }
+    // if (this instanceof VMThinRegionEntryLongKey) {
+    // factory.returnToPool((VMThinRegionEntryLongKey)this);
+    // }
   }
 
   protected long getLastModifiedField() {
     return lastModifiedUpdater.get(this);
   }
+
   protected boolean compareAndSetLastModifiedField(long expectedValue, long newValue) {
     return lastModifiedUpdater.compareAndSet(this, expectedValue, newValue);
   }
+
   /**
    * @see HashEntry#getEntryHash()
    */
   public int getEntryHash() {
     return this.hash;
   }
+
   protected void setEntryHash(int v) {
     this.hash = v;
   }
+
   /**
    * @see HashEntry#getNextEntry()
    */
   public HashEntry<Object, Object> getNextEntry() {
     return this.next;
   }
+
   /**
    * @see HashEntry#setNextEntry
    */
@@ -203,12 +204,13 @@ public class VersionedThinDiskRegionEntryOffHeapLongKey extends VersionedThinDis
 
 
   // DO NOT modify this class. It was generated from LeafRegionEntry.cpp
-  
+
   // disk code
 
   protected void initialize(RegionEntryContext context, Object value) {
     diskInitialize(context, value);
   }
+
   @Override
   public int updateAsyncEntrySize(EnableLRU capacityController) {
     throw new IllegalStateException("should never be called");
@@ -216,12 +218,12 @@ public class VersionedThinDiskRegionEntryOffHeapLongKey extends VersionedThinDis
 
 
   // DO NOT modify this class. It was generated from LeafRegionEntry.cpp
-  
+
   private void diskInitialize(RegionEntryContext context, Object value) {
-    DiskRecoveryStore drs = (DiskRecoveryStore)context;
+    DiskRecoveryStore drs = (DiskRecoveryStore) context;
     DiskStoreImpl ds = drs.getDiskStore();
     long maxOplogSize = ds.getMaxOplogSize();
-    //get appropriate instance of DiskId implementation based on maxOplogSize
+    // get appropriate instance of DiskId implementation based on maxOplogSize
     this.id = DiskId.createDiskId(maxOplogSize, true/* is persistence */, ds.needsLinkedList());
     Helper.initialize(this, drs, value);
   }
@@ -231,62 +233,60 @@ public class VersionedThinDiskRegionEntryOffHeapLongKey extends VersionedThinDis
    * 
    * @since GemFire 5.1
    */
-  protected DiskId id;//= new DiskId();
+  protected DiskId id;// = new DiskId();
+
   public DiskId getDiskId() {
     return this.id;
   }
+
   @Override
   void setDiskId(RegionEntry old) {
-    this.id = ((AbstractDiskRegionEntry)old).getDiskId();
-  }
-//  // inlining DiskId
-//  // always have these fields
-//  /**
-//   * id consists of
-//   * most significant
-//   * 1 byte = users bits
-//   * 2-8 bytes = oplog id
-//   * least significant.
-//   * 
-//   * The highest bit in the oplog id part is set to 1 if the oplog id
-//   * is negative.
-//   * @todo this field could be an int for an overflow only region
-//   */
-//  private long id;
-//  /**
-//   * Length of the bytes on disk.
-//   * This is always set. If the value is invalid then it will be set to 0.
-//   * The most significant bit is used by overflow to mark it as needing to be written.
-//   */
-//  protected int valueLength = 0;
-//  // have intOffset or longOffset
-//  // intOffset
-//  /**
-//   * The position in the oplog (the oplog offset) where this entry's value is
-//   * stored
-//   */
-//  private volatile int offsetInOplog;
-//  // longOffset
-//  /**
-//   * The position in the oplog (the oplog offset) where this entry's value is
-//   * stored
-//   */
-//  private volatile long offsetInOplog;
-//  // have overflowOnly or persistence
-//  // overflowOnly
-//  // no fields
-//  // persistent
-//  /** unique entry identifier * */
-//  private long keyId;
-
-  
-
-
-
-  
+    this.id = ((AbstractDiskRegionEntry) old).getDiskId();
+  }
+  // // inlining DiskId
+  // // always have these fields
+  // /**
+  // * id consists of
+  // * most significant
+  // * 1 byte = users bits
+  // * 2-8 bytes = oplog id
+  // * least significant.
+  // *
+  // * The highest bit in the oplog id part is set to 1 if the oplog id
+  // * is negative.
+  // * @todo this field could be an int for an overflow only region
+  // */
+  // private long id;
+  // /**
+  // * Length of the bytes on disk.
+  // * This is always set. If the value is invalid then it will be set to 0.
+  // * The most significant bit is used by overflow to mark it as needing to be written.
+  // */
+  // protected int valueLength = 0;
+  // // have intOffset or longOffset
+  // // intOffset
+  // /**
+  // * The position in the oplog (the oplog offset) where this entry's value is
+  // * stored
+  // */
+  // private volatile int offsetInOplog;
+  // // longOffset
+  // /**
+  // * The position in the oplog (the oplog offset) where this entry's value is
+  // * stored
+  // */
+  // private volatile long offsetInOplog;
+  // // have overflowOnly or persistence
+  // // overflowOnly
+  // // no fields
+  // // persistent
+  // /** unique entry identifier * */
+  // private long keyId;
+
+
 
   // DO NOT modify this class. It was generated from LeafRegionEntry.cpp
-  
+
   // versioned code
   private VersionSource memberID;
   private short entryVersionLowBytes;
@@ -298,16 +298,16 @@ public class VersionedThinDiskRegionEntryOffHeapLongKey extends VersionedThinDis
   public int getEntryVersion() {
     return ((entryVersionHighByte << 16) & 0xFF0000) | (entryVersionLowBytes & 0xFFFF);
   }
-  
+
   public long getRegionVersion() {
-    return (((long)regionVersionHighBytes) << 32) | (regionVersionLowBytes & 0x00000000FFFFFFFFL);  
+    return (((long) regionVersionHighBytes) << 32) | (regionVersionLowBytes & 0x00000000FFFFFFFFL);
   }
-  
-  
+
+
   public long getVersionTimeStamp() {
     return getLastModified();
   }
-  
+
   public void setVersionTimeStamp(long time) {
     setLastModified(time);
   }
@@ -315,17 +315,18 @@ public class VersionedThinDiskRegionEntryOffHeapLongKey extends VersionedThinDis
   public VersionSource getMemberID() {
     return this.memberID;
   }
+
   public int getDistributedSystemId() {
     return this.distributedSystemId;
   }
 
   // DO NOT modify this class. It was generated from LeafRegionEntry.cpp
-  
+
   public void setVersions(VersionTag tag) {
     this.memberID = tag.getMemberID();
     int eVersion = tag.getEntryVersion();
-    this.entryVersionLowBytes = (short)(eVersion & 0xffff);
-    this.entryVersionHighByte = (byte)((eVersion & 0xff0000) >> 16);
+    this.entryVersionLowBytes = (short) (eVersion & 0xffff);
+    this.entryVersionHighByte = (byte) ((eVersion & 0xff0000) >> 16);
     this.regionVersionHighBytes = tag.getRegionVersionHighBytes();
     this.regionVersionLowBytes = tag.getRegionVersionLowBytes();
     if (!(tag.isGatewayTag()) && this.distributedSystemId == tag.getDistributedSystemId()) {
@@ -337,11 +338,11 @@ public class VersionedThinDiskRegionEntryOffHeapLongKey extends VersionedThinDis
     } else {
       setVersionTimeStamp(tag.getVersionTimeStamp());
     }
-    this.distributedSystemId = (byte)(tag.getDistributedSystemId() & 0xff);
+    this.distributedSystemId = (byte) (tag.getDistributedSystemId() & 0xff);
   }
 
   public void setMemberID(VersionSource memberID) {
-    this.memberID = memberID; 
+    this.memberID = memberID;
   }
 
   @Override
@@ -350,7 +351,7 @@ public class VersionedThinDiskRegionEntryOffHeapLongKey extends VersionedThinDis
   }
 
   // DO NOT modify this class. It was generated from LeafRegionEntry.cpp
-  
+
   public VersionTag asVersionTag() {
     VersionTag tag = VersionTag.create(memberID);
     tag.setEntryVersion(getEntryVersion());
@@ -360,9 +361,9 @@ public class VersionedThinDiskRegionEntryOffHeapLongKey extends VersionedThinDis
     return tag;
   }
 
-  public void processVersionTag(LocalRegion r, VersionTag tag,
-      boolean isTombstoneFromGII, boolean hasDelta,
-      VersionSource thisVM, InternalDistributedMember sender, boolean checkForConflicts) {
+  public void processVersionTag(LocalRegion r, VersionTag tag, boolean isTombstoneFromGII,
+      boolean hasDelta, VersionSource thisVM, InternalDistributedMember sender,
+      boolean checkForConflicts) {
     basicProcessVersionTag(r, tag, isTombstoneFromGII, hasDelta, thisVM, sender, checkForConflicts);
   }
 
@@ -377,22 +378,24 @@ public class VersionedThinDiskRegionEntryOffHeapLongKey extends VersionedThinDis
   public short getRegionVersionHighBytes() {
     return this.regionVersionHighBytes;
   }
-  
+
   /** get rvv internal low bytes. Used by region entries for transferring to storage */
   public int getRegionVersionLowBytes() {
     return this.regionVersionLowBytes;
   }
 
-  
+
   // DO NOT modify this class. It was generated from LeafRegionEntry.cpp
-  
+
   // key code
 
   private final long key;
+
   @Override
   public Object getKey() {
     return this.key;
   }
+
   @Override
   public boolean isKeyEqual(Object k) {
     if (k instanceof Long) {
@@ -400,7 +403,7 @@ public class VersionedThinDiskRegionEntryOffHeapLongKey extends VersionedThinDis
     }
     return false;
   }
-  
+
 
   // DO NOT modify this class. It was generated from LeafRegionEntry.cpp
 }

http://git-wip-us.apache.org/repos/asf/geode/blob/5adb681a/geode-core/src/main/java/org/apache/geode/internal/cache/VersionedThinDiskRegionEntryOffHeapObjectKey.java
----------------------------------------------------------------------
diff --git a/geode-core/src/main/java/org/apache/geode/internal/cache/VersionedThinDiskRegionEntryOffHeapObjectKey.java b/geode-core/src/main/java/org/apache/geode/internal/cache/VersionedThinDiskRegionEntryOffHeapObjectKey.java
index cef4f3a..9f0055e 100644
--- a/geode-core/src/main/java/org/apache/geode/internal/cache/VersionedThinDiskRegionEntryOffHeapObjectKey.java
+++ b/geode-core/src/main/java/org/apache/geode/internal/cache/VersionedThinDiskRegionEntryOffHeapObjectKey.java
@@ -18,19 +18,12 @@ package org.apache.geode.internal.cache;
 
 
 
-
-
-
-
-
 import java.util.concurrent.atomic.AtomicLongFieldUpdater;
 
 import org.apache.geode.cache.EntryEvent;
 
-
 import org.apache.geode.internal.cache.lru.EnableLRU;
 
-
 import org.apache.geode.internal.cache.persistence.DiskRecoveryStore;
 
 import org.apache.geode.distributed.internal.membership.InternalDistributedMember;
@@ -38,7 +31,6 @@ import org.apache.geode.internal.cache.versions.VersionSource;
 import org.apache.geode.internal.cache.versions.VersionStamp;
 import org.apache.geode.internal.cache.versions.VersionTag;
 
-
 import org.apache.geode.internal.offheap.OffHeapRegionEntryHelper;
 import org.apache.geode.internal.offheap.annotations.Released;
 import org.apache.geode.internal.offheap.annotations.Retained;
@@ -64,8 +56,9 @@ import org.apache.geode.internal.util.concurrent.CustomEntryConcurrentHashMap.Ha
  * Do not modify this class. It was generated. Instead modify LeafRegionEntry.cpp and then run
  * ./dev-tools/generateRegionEntryClasses.sh (it must be run from the top level directory).
  */
-public class VersionedThinDiskRegionEntryOffHeapObjectKey extends VersionedThinDiskRegionEntryOffHeap {
-  public VersionedThinDiskRegionEntryOffHeapObjectKey  (RegionEntryContext context, Object key, 
+public class VersionedThinDiskRegionEntryOffHeapObjectKey
+    extends VersionedThinDiskRegionEntryOffHeap {
+  public VersionedThinDiskRegionEntryOffHeapObjectKey(RegionEntryContext context, Object key,
 
       @Retained
 
@@ -73,14 +66,14 @@ public class VersionedThinDiskRegionEntryOffHeapObjectKey extends VersionedThinD
 
 
 
-      ) {
-    super(context, 
+  ) {
+    super(context,
 
-          (value instanceof RecoveredEntry ? null : value)
+        (value instanceof RecoveredEntry ? null : value)
 
 
 
-        );
+    );
     // DO NOT modify this class. It was generated from LeafRegionEntry.cpp
 
     initialize(context, value);
@@ -91,35 +84,40 @@ public class VersionedThinDiskRegionEntryOffHeapObjectKey extends VersionedThinD
   }
 
   // DO NOT modify this class. It was generated from LeafRegionEntry.cpp
-  
+
   // common code
   protected int hash;
   private HashEntry<Object, Object> next;
   @SuppressWarnings("unused")
   private volatile long lastModified;
-  private static final AtomicLongFieldUpdater<VersionedThinDiskRegionEntryOffHeapObjectKey> lastModifiedUpdater
-    = AtomicLongFieldUpdater.newUpdater(VersionedThinDiskRegionEntryOffHeapObjectKey.class, "lastModified");
+  private static final AtomicLongFieldUpdater<VersionedThinDiskRegionEntryOffHeapObjectKey> lastModifiedUpdater =
+      AtomicLongFieldUpdater.newUpdater(VersionedThinDiskRegionEntryOffHeapObjectKey.class,
+          "lastModified");
 
   /**
    * All access done using ohAddrUpdater so it is used even though the compiler can not tell it is.
    */
   @SuppressWarnings("unused")
-  @Retained @Released private volatile long ohAddress;
+  @Retained
+  @Released
+  private volatile long ohAddress;
   /**
-   * I needed to add this because I wanted clear to call setValue which normally can only be called while the re is synced.
-   * But if I sync in that code it causes a lock ordering deadlock with the disk regions because they also get a rw lock in clear.
-   * Some hardware platforms do not support CAS on a long. If gemfire is run on one of those the AtomicLongFieldUpdater does a sync
-   * on the re and we will once again be deadlocked.
-   * I don't know if we support any of the hardware platforms that do not have a 64bit CAS. If we do then we can expect deadlocks
-   * on disk regions.
+   * I needed to add this because I wanted clear to call setValue which normally can only be called
+   * while the re is synced. But if I sync in that code it causes a lock ordering deadlock with the
+   * disk regions because they also get a rw lock in clear. Some hardware platforms do not support
+   * CAS on a long. If gemfire is run on one of those the AtomicLongFieldUpdater does a sync on the
+   * re and we will once again be deadlocked. I don't know if we support any of the hardware
+   * platforms that do not have a 64bit CAS. If we do then we can expect deadlocks on disk regions.
    */
-  private final static AtomicLongFieldUpdater<VersionedThinDiskRegionEntryOffHeapObjectKey> ohAddrUpdater = AtomicLongFieldUpdater.newUpdater(VersionedThinDiskRegionEntryOffHeapObjectKey.class, "ohAddress");
-  
+  private final static AtomicLongFieldUpdater<VersionedThinDiskRegionEntryOffHeapObjectKey> ohAddrUpdater =
+      AtomicLongFieldUpdater.newUpdater(VersionedThinDiskRegionEntryOffHeapObjectKey.class,
+          "ohAddress");
+
   @Override
   public Token getValueAsToken() {
     return OffHeapRegionEntryHelper.getValueAsToken(this);
   }
-  
+
   @Override
   protected Object getValueField() {
     return OffHeapRegionEntryHelper._getValue(this);
@@ -135,6 +133,7 @@ public class VersionedThinDiskRegionEntryOffHeapObjectKey extends VersionedThinD
 
     OffHeapRegionEntryHelper.setValue(this, v);
   }
+
   @Override
 
   @Retained
@@ -152,7 +151,7 @@ public class VersionedThinDiskRegionEntryOffHeapObjectKey extends VersionedThinD
   public boolean setAddress(long expectedAddr, long newAddr) {
     return ohAddrUpdater.compareAndSet(this, expectedAddr, newAddr);
   }
-  
+
   @Override
 
   @Released
@@ -160,36 +159,41 @@ public class VersionedThinDiskRegionEntryOffHeapObjectKey extends VersionedThinD
   public void release() {
     OffHeapRegionEntryHelper.releaseEntry(this);
   }
-  
+
   @Override
   public void returnToPool() {
     // Deadcoded for now; never was working
-//    if (this instanceof VMThinRegionEntryLongKey) {
-//      factory.returnToPool((VMThinRegionEntryLongKey)this);
-//    }
+    // if (this instanceof VMThinRegionEntryLongKey) {
+    // factory.returnToPool((VMThinRegionEntryLongKey)this);
+    // }
   }
 
   protected long getLastModifiedField() {
     return lastModifiedUpdater.get(this);
   }
+
   protected boolean compareAndSetLastModifiedField(long expectedValue, long newValue) {
     return lastModifiedUpdater.compareAndSet(this, expectedValue, newValue);
   }
+
   /**
    * @see HashEntry#getEntryHash()
    */
   public int getEntryHash() {
     return this.hash;
   }
+
   protected void setEntryHash(int v) {
     this.hash = v;
   }
+
   /**
    * @see HashEntry#getNextEntry()
    */
   public HashEntry<Object, Object> getNextEntry() {
     return this.next;
   }
+
   /**
    * @see HashEntry#setNextEntry
    */
@@ -199,12 +203,13 @@ public class VersionedThinDiskRegionEntryOffHeapObjectKey extends VersionedThinD
 
 
   // DO NOT modify this class. It was generated from LeafRegionEntry.cpp
-  
+
   // disk code
 
   protected void initialize(RegionEntryContext context, Object value) {
     diskInitialize(context, value);
   }
+
   @Override
   public int updateAsyncEntrySize(EnableLRU capacityController) {
     throw new IllegalStateException("should never be called");
@@ -212,12 +217,12 @@ public class VersionedThinDiskRegionEntryOffHeapObjectKey extends VersionedThinD
 
 
   // DO NOT modify this class. It was generated from LeafRegionEntry.cpp
-  
+
   private void diskInitialize(RegionEntryContext context, Object value) {
-    DiskRecoveryStore drs = (DiskRecoveryStore)context;
+    DiskRecoveryStore drs = (DiskRecoveryStore) context;
     DiskStoreImpl ds = drs.getDiskStore();
     long maxOplogSize = ds.getMaxOplogSize();
-    //get appropriate instance of DiskId implementation based on maxOplogSize
+    // get appropriate instance of DiskId implementation based on maxOplogSize
     this.id = DiskId.createDiskId(maxOplogSize, true/* is persistence */, ds.needsLinkedList());
     Helper.initialize(this, drs, value);
   }
@@ -227,62 +232,60 @@ public class VersionedThinDiskRegionEntryOffHeapObjectKey extends VersionedThinD
    * 
    * @since GemFire 5.1
    */
-  protected DiskId id;//= new DiskId();
+  protected DiskId id;// = new DiskId();
+
   public DiskId getDiskId() {
     return this.id;
   }
+
   @Override
   void setDiskId(RegionEntry old) {
-    this.id = ((AbstractDiskRegionEntry)old).getDiskId();
-  }
-//  // inlining DiskId
-//  // always have these fields
-//  /**
-//   * id consists of
-//   * most significant
-//   * 1 byte = users bits
-//   * 2-8 bytes = oplog id
-//   * least significant.
-//   * 
-//   * The highest bit in the oplog id part is set to 1 if the oplog id
-//   * is negative.
-//   * @todo this field could be an int for an overflow only region
-//   */
-//  private long id;
-//  /**
-//   * Length of the bytes on disk.
-//   * This is always set. If the value is invalid then it will be set to 0.
-//   * The most significant bit is used by overflow to mark it as needing to be written.
-//   */
-//  protected int valueLength = 0;
-//  // have intOffset or longOffset
-//  // intOffset
-//  /**
-//   * The position in the oplog (the oplog offset) where this entry's value is
-//   * stored
-//   */
-//  private volatile int offsetInOplog;
-//  // longOffset
-//  /**
-//   * The position in the oplog (the oplog offset) where this entry's value is
-//   * stored
-//   */
-//  private volatile long offsetInOplog;
-//  // have overflowOnly or persistence
-//  // overflowOnly
-//  // no fields
-//  // persistent
-//  /** unique entry identifier * */
-//  private long keyId;
-
-  
-
-
-
-  
+    this.id = ((AbstractDiskRegionEntry) old).getDiskId();
+  }
+  // // inlining DiskId
+  // // always have these fields
+  // /**
+  // * id consists of
+  // * most significant
+  // * 1 byte = users bits
+  // * 2-8 bytes = oplog id
+  // * least significant.
+  // *
+  // * The highest bit in the oplog id part is set to 1 if the oplog id
+  // * is negative.
+  // * @todo this field could be an int for an overflow only region
+  // */
+  // private long id;
+  // /**
+  // * Length of the bytes on disk.
+  // * This is always set. If the value is invalid then it will be set to 0.
+  // * The most significant bit is used by overflow to mark it as needing to be written.
+  // */
+  // protected int valueLength = 0;
+  // // have intOffset or longOffset
+  // // intOffset
+  // /**
+  // * The position in the oplog (the oplog offset) where this entry's value is
+  // * stored
+  // */
+  // private volatile int offsetInOplog;
+  // // longOffset
+  // /**
+  // * The position in the oplog (the oplog offset) where this entry's value is
+  // * stored
+  // */
+  // private volatile long offsetInOplog;
+  // // have overflowOnly or persistence
+  // // overflowOnly
+  // // no fields
+  // // persistent
+  // /** unique entry identifier * */
+  // private long keyId;
+
+
 
   // DO NOT modify this class. It was generated from LeafRegionEntry.cpp
-  
+
   // versioned code
   private VersionSource memberID;
   private short entryVersionLowBytes;
@@ -294,16 +297,16 @@ public class VersionedThinDiskRegionEntryOffHeapObjectKey extends VersionedThinD
   public int getEntryVersion() {
     return ((entryVersionHighByte << 16) & 0xFF0000) | (entryVersionLowBytes & 0xFFFF);
   }
-  
+
   public long getRegionVersion() {
-    return (((long)regionVersionHighBytes) << 32) | (regionVersionLowBytes & 0x00000000FFFFFFFFL);  
+    return (((long) regionVersionHighBytes) << 32) | (regionVersionLowBytes & 0x00000000FFFFFFFFL);
   }
-  
-  
+
+
   public long getVersionTimeStamp() {
     return getLastModified();
   }
-  
+
   public void setVersionTimeStamp(long time) {
     setLastModified(time);
   }
@@ -311,17 +314,18 @@ public class VersionedThinDiskRegionEntryOffHeapObjectKey extends VersionedThinD
   public VersionSource getMemberID() {
     return this.memberID;
   }
+
   public int getDistributedSystemId() {
     return this.distributedSystemId;
   }
 
   // DO NOT modify this class. It was generated from LeafRegionEntry.cpp
-  
+
   public void setVersions(VersionTag tag) {
     this.memberID = tag.getMemberID();
     int eVersion = tag.getEntryVersion();
-    this.entryVersionLowBytes = (short)(eVersion & 0xffff);
-    this.entryVersionHighByte = (byte)((eVersion & 0xff0000) >> 16);
+    this.entryVersionLowBytes = (short) (eVersion & 0xffff);
+    this.entryVersionHighByte = (byte) ((eVersion & 0xff0000) >> 16);
     this.regionVersionHighBytes = tag.getRegionVersionHighBytes();
     this.regionVersionLowBytes = tag.getRegionVersionLowBytes();
     if (!(tag.isGatewayTag()) && this.distributedSystemId == tag.getDistributedSystemId()) {
@@ -333,11 +337,11 @@ public class VersionedThinDiskRegionEntryOffHeapObjectKey extends VersionedThinD
     } else {
       setVersionTimeStamp(tag.getVersionTimeStamp());
     }
-    this.distributedSystemId = (byte)(tag.getDistributedSystemId() & 0xff);
+    this.distributedSystemId = (byte) (tag.getDistributedSystemId() & 0xff);
   }
 
   public void setMemberID(VersionSource memberID) {
-    this.memberID = memberID; 
+    this.memberID = memberID;
   }
 
   @Override
@@ -346,7 +350,7 @@ public class VersionedThinDiskRegionEntryOffHeapObjectKey extends VersionedThinD
   }
 
   // DO NOT modify this class. It was generated from LeafRegionEntry.cpp
-  
+
   public VersionTag asVersionTag() {
     VersionTag tag = VersionTag.create(memberID);
     tag.setEntryVersion(getEntryVersion());
@@ -356,9 +360,9 @@ public class VersionedThinDiskRegionEntryOffHeapObjectKey extends VersionedThinD
     return tag;
   }
 
-  public void processVersionTag(LocalRegion r, VersionTag tag,
-      boolean isTombstoneFromGII, boolean hasDelta,
-      VersionSource thisVM, InternalDistributedMember sender, boolean checkForConflicts) {
+  public void processVersionTag(LocalRegion r, VersionTag tag, boolean isTombstoneFromGII,
+      boolean hasDelta, VersionSource thisVM, InternalDistributedMember sender,
+      boolean checkForConflicts) {
     basicProcessVersionTag(r, tag, isTombstoneFromGII, hasDelta, thisVM, sender, checkForConflicts);
   }
 
@@ -373,18 +377,19 @@ public class VersionedThinDiskRegionEntryOffHeapObjectKey extends VersionedThinD
   public short getRegionVersionHighBytes() {
     return this.regionVersionHighBytes;
   }
-  
+
   /** get rvv internal low bytes. Used by region entries for transferring to storage */
   public int getRegionVersionLowBytes() {
     return this.regionVersionLowBytes;
   }
 
-  
+
   // DO NOT modify this class. It was generated from LeafRegionEntry.cpp
-  
+
   // key code
 
   private final Object key;
+
   @Override
   public Object getKey() {
     return this.key;

http://git-wip-us.apache.org/repos/asf/geode/blob/5adb681a/geode-core/src/main/java/org/apache/geode/internal/cache/VersionedThinDiskRegionEntryOffHeapStringKey1.java
----------------------------------------------------------------------
diff --git a/geode-core/src/main/java/org/apache/geode/internal/cache/VersionedThinDiskRegionEntryOffHeapStringKey1.java b/geode-core/src/main/java/org/apache/geode/internal/cache/VersionedThinDiskRegionEntryOffHeapStringKey1.java
index 7c0a3a2..34b5e68 100644
--- a/geode-core/src/main/java/org/apache/geode/internal/cache/VersionedThinDiskRegionEntryOffHeapStringKey1.java
+++ b/geode-core/src/main/java/org/apache/geode/internal/cache/VersionedThinDiskRegionEntryOffHeapStringKey1.java
@@ -18,19 +18,12 @@ package org.apache.geode.internal.cache;
 
 
 
-
-
-
-
-
 import java.util.concurrent.atomic.AtomicLongFieldUpdater;
 
 import org.apache.geode.cache.EntryEvent;
 
-
 import org.apache.geode.internal.cache.lru.EnableLRU;
 
-
 import org.apache.geode.internal.cache.persistence.DiskRecoveryStore;
 
 import org.apache.geode.distributed.internal.membership.InternalDistributedMember;
@@ -38,7 +31,6 @@ import org.apache.geode.internal.cache.versions.VersionSource;
 import org.apache.geode.internal.cache.versions.VersionStamp;
 import org.apache.geode.internal.cache.versions.VersionTag;
 
-
 import org.apache.geode.internal.offheap.OffHeapRegionEntryHelper;
 import org.apache.geode.internal.offheap.annotations.Released;
 import org.apache.geode.internal.offheap.annotations.Retained;
@@ -64,8 +56,9 @@ import org.apache.geode.internal.util.concurrent.CustomEntryConcurrentHashMap.Ha
  * Do not modify this class. It was generated. Instead modify LeafRegionEntry.cpp and then run
  * ./dev-tools/generateRegionEntryClasses.sh (it must be run from the top level directory).
  */
-public class VersionedThinDiskRegionEntryOffHeapStringKey1 extends VersionedThinDiskRegionEntryOffHeap {
-  public VersionedThinDiskRegionEntryOffHeapStringKey1  (RegionEntryContext context, String key, 
+public class VersionedThinDiskRegionEntryOffHeapStringKey1
+    extends VersionedThinDiskRegionEntryOffHeap {
+  public VersionedThinDiskRegionEntryOffHeapStringKey1(RegionEntryContext context, String key,
 
       @Retained
 
@@ -73,14 +66,14 @@ public class VersionedThinDiskRegionEntryOffHeapStringKey1 extends VersionedThin
 
       , boolean byteEncode
 
-      ) {
-    super(context, 
+  ) {
+    super(context,
 
-          (value instanceof RecoveredEntry ? null : value)
+        (value instanceof RecoveredEntry ? null : value)
 
 
 
-        );
+    );
     // DO NOT modify this class. It was generated from LeafRegionEntry.cpp
 
     initialize(context, value);
@@ -88,14 +81,15 @@ public class VersionedThinDiskRegionEntryOffHeapStringKey1 extends VersionedThin
     // caller has already confirmed that key.length <= MAX_INLINE_STRING_KEY
     long tmpBits1 = 0L;
     if (byteEncode) {
-      for (int i=key.length()-1; i >= 0; i--) {
-        // Note: we know each byte is <= 0x7f so the "& 0xff" is not needed. But I added it in to keep findbugs happy.
-        tmpBits1 |= (byte)key.charAt(i) & 0xff;
+      for (int i = key.length() - 1; i >= 0; i--) {
+        // Note: we know each byte is <= 0x7f so the "& 0xff" is not needed. But I added it in to
+        // keep findbugs happy.
+        tmpBits1 |= (byte) key.charAt(i) & 0xff;
         tmpBits1 <<= 8;
       }
-      tmpBits1 |= 1<<6;
+      tmpBits1 |= 1 << 6;
     } else {
-      for (int i=key.length()-1; i >= 0; i--) {
+      for (int i = key.length() - 1; i >= 0; i--) {
         tmpBits1 |= key.charAt(i);
         tmpBits1 <<= 16;
       }
@@ -106,35 +100,40 @@ public class VersionedThinDiskRegionEntryOffHeapStringKey1 extends VersionedThin
   }
 
   // DO NOT modify this class. It was generated from LeafRegionEntry.cpp
-  
+
   // common code
   protected int hash;
   private HashEntry<Object, Object> next;
   @SuppressWarnings("unused")
   private volatile long lastModified;
-  private static final AtomicLongFieldUpdater<VersionedThinDiskRegionEntryOffHeapStringKey1> lastModifiedUpdater
-    = AtomicLongFieldUpdater.newUpdater(VersionedThinDiskRegionEntryOffHeapStringKey1.class, "lastModified");
+  private static final AtomicLongFieldUpdater<VersionedThinDiskRegionEntryOffHeapStringKey1> lastModifiedUpdater =
+      AtomicLongFieldUpdater.newUpdater(VersionedThinDiskRegionEntryOffHeapStringKey1.class,
+          "lastModified");
 
   /**
    * All access done using ohAddrUpdater so it is used even though the compiler can not tell it is.
    */
   @SuppressWarnings("unused")
-  @Retained @Released private volatile long ohAddress;
+  @Retained
+  @Released
+  private volatile long ohAddress;
   /**
-   * I needed to add this because I wanted clear to call setValue which normally can only be called while the re is synced.
-   * But if I sync in that code it causes a lock ordering deadlock with the disk regions because they also get a rw lock in clear.
-   * Some hardware platforms do not support CAS on a long. If gemfire is run on one of those the AtomicLongFieldUpdater does a sync
-   * on the re and we will once again be deadlocked.
-   * I don't know if we support any of the hardware platforms that do not have a 64bit CAS. If we do then we can expect deadlocks
-   * on disk regions.
+   * I needed to add this because I wanted clear to call setValue which normally can only be called
+   * while the re is synced. But if I sync in that code it causes a lock ordering deadlock with the
+   * disk regions because they also get a rw lock in clear. Some hardware platforms do not support
+   * CAS on a long. If gemfire is run on one of those the AtomicLongFieldUpdater does a sync on the
+   * re and we will once again be deadlocked. I don't know if we support any of the hardware
+   * platforms that do not have a 64bit CAS. If we do then we can expect deadlocks on disk regions.
    */
-  private final static AtomicLongFieldUpdater<VersionedThinDiskRegionEntryOffHeapStringKey1> ohAddrUpdater = AtomicLongFieldUpdater.newUpdater(VersionedThinDiskRegionEntryOffHeapStringKey1.class, "ohAddress");
-  
+  private final static AtomicLongFieldUpdater<VersionedThinDiskRegionEntryOffHeapStringKey1> ohAddrUpdater =
+      AtomicLongFieldUpdater.newUpdater(VersionedThinDiskRegionEntryOffHeapStringKey1.class,
+          "ohAddress");
+
   @Override
   public Token getValueAsToken() {
     return OffHeapRegionEntryHelper.getValueAsToken(this);
   }
-  
+
   @Override
   protected Object getValueField() {
     return OffHeapRegionEntryHelper._getValue(this);
@@ -150,6 +149,7 @@ public class VersionedThinDiskRegionEntryOffHeapStringKey1 extends VersionedThin
 
     OffHeapRegionEntryHelper.setValue(this, v);
   }
+
   @Override
 
   @Retained
@@ -167,7 +167,7 @@ public class VersionedThinDiskRegionEntryOffHeapStringKey1 extends VersionedThin
   public boolean setAddress(long expectedAddr, long newAddr) {
     return ohAddrUpdater.compareAndSet(this, expectedAddr, newAddr);
   }
-  
+
   @Override
 
   @Released
@@ -175,36 +175,41 @@ public class VersionedThinDiskRegionEntryOffHeapStringKey1 extends VersionedThin
   public void release() {
     OffHeapRegionEntryHelper.releaseEntry(this);
   }
-  
+
   @Override
   public void returnToPool() {
     // Deadcoded for now; never was working
-//    if (this instanceof VMThinRegionEntryLongKey) {
-//      factory.returnToPool((VMThinRegionEntryLongKey)this);
-//    }
+    // if (this instanceof VMThinRegionEntryLongKey) {
+    // factory.returnToPool((VMThinRegionEntryLongKey)this);
+    // }
   }
 
   protected long getLastModifiedField() {
     return lastModifiedUpdater.get(this);
   }
+
   protected boolean compareAndSetLastModifiedField(long expectedValue, long newValue) {
     return lastModifiedUpdater.compareAndSet(this, expectedValue, newValue);
   }
+
   /**
    * @see HashEntry#getEntryHash()
    */
   public int getEntryHash() {
     return this.hash;
   }
+
   protected void setEntryHash(int v) {
     this.hash = v;
   }
+
   /**
    * @see HashEntry#getNextEntry()
    */
   public HashEntry<Object, Object> getNextEntry() {
     return this.next;
   }
+
   /**
    * @see HashEntry#setNextEntry
    */
@@ -214,12 +219,13 @@ public class VersionedThinDiskRegionEntryOffHeapStringKey1 extends VersionedThin
 
 
   // DO NOT modify this class. It was generated from LeafRegionEntry.cpp
-  
+
   // disk code
 
   protected void initialize(RegionEntryContext context, Object value) {
     diskInitialize(context, value);
   }
+
   @Override
   public int updateAsyncEntrySize(EnableLRU capacityController) {
     throw new IllegalStateException("should never be called");
@@ -227,12 +233,12 @@ public class VersionedThinDiskRegionEntryOffHeapStringKey1 extends VersionedThin
 
 
   // DO NOT modify this class. It was generated from LeafRegionEntry.cpp
-  
+
   private void diskInitialize(RegionEntryContext context, Object value) {
-    DiskRecoveryStore drs = (DiskRecoveryStore)context;
+    DiskRecoveryStore drs = (DiskRecoveryStore) context;
     DiskStoreImpl ds = drs.getDiskStore();
     long maxOplogSize = ds.getMaxOplogSize();
-    //get appropriate instance of DiskId implementation based on maxOplogSize
+    // get appropriate instance of DiskId implementation based on maxOplogSize
     this.id = DiskId.createDiskId(maxOplogSize, true/* is persistence */, ds.needsLinkedList());
     Helper.initialize(this, drs, value);
   }
@@ -242,62 +248,60 @@ public class VersionedThinDiskRegionEntryOffHeapStringKey1 extends VersionedThin
    * 
    * @since GemFire 5.1
    */
-  protected DiskId id;//= new DiskId();
+  protected DiskId id;// = new DiskId();
+
   public DiskId getDiskId() {
     return this.id;
   }
+
   @Override
   void setDiskId(RegionEntry old) {
-    this.id = ((AbstractDiskRegionEntry)old).getDiskId();
-  }
-//  // inlining DiskId
-//  // always have these fields
-//  /**
-//   * id consists of
-//   * most significant
-//   * 1 byte = users bits
-//   * 2-8 bytes = oplog id
-//   * least significant.
-//   * 
-//   * The highest bit in the oplog id part is set to 1 if the oplog id
-//   * is negative.
-//   * @todo this field could be an int for an overflow only region
-//   */
-//  private long id;
-//  /**
-//   * Length of the bytes on disk.
-//   * This is always set. If the value is invalid then it will be set to 0.
-//   * The most significant bit is used by overflow to mark it as needing to be written.
-//   */
-//  protected int valueLength = 0;
-//  // have intOffset or longOffset
-//  // intOffset
-//  /**
-//   * The position in the oplog (the oplog offset) where this entry's value is
-//   * stored
-//   */
-//  private volatile int offsetInOplog;
-//  // longOffset
-//  /**
-//   * The position in the oplog (the oplog offset) where this entry's value is
-//   * stored
-//   */
-//  private volatile long offsetInOplog;
-//  // have overflowOnly or persistence
-//  // overflowOnly
-//  // no fields
-//  // persistent
-//  /** unique entry identifier * */
-//  private long keyId;
-
-  
-
-
-
-  
+    this.id = ((AbstractDiskRegionEntry) old).getDiskId();
+  }
+  // // inlining DiskId
+  // // always have these fields
+  // /**
+  // * id consists of
+  // * most significant
+  // * 1 byte = users bits
+  // * 2-8 bytes = oplog id
+  // * least significant.
+  // *
+  // * The highest bit in the oplog id part is set to 1 if the oplog id
+  // * is negative.
+  // * @todo this field could be an int for an overflow only region
+  // */
+  // private long id;
+  // /**
+  // * Length of the bytes on disk.
+  // * This is always set. If the value is invalid then it will be set to 0.
+  // * The most significant bit is used by overflow to mark it as needing to be written.
+  // */
+  // protected int valueLength = 0;
+  // // have intOffset or longOffset
+  // // intOffset
+  // /**
+  // * The position in the oplog (the oplog offset) where this entry's value is
+  // * stored
+  // */
+  // private volatile int offsetInOplog;
+  // // longOffset
+  // /**
+  // * The position in the oplog (the oplog offset) where this entry's value is
+  // * stored
+  // */
+  // private volatile long offsetInOplog;
+  // // have overflowOnly or persistence
+  // // overflowOnly
+  // // no fields
+  // // persistent
+  // /** unique entry identifier * */
+  // private long keyId;
+
+
 
   // DO NOT modify this class. It was generated from LeafRegionEntry.cpp
-  
+
   // versioned code
   private VersionSource memberID;
   private short entryVersionLowBytes;
@@ -309,16 +313,16 @@ public class VersionedThinDiskRegionEntryOffHeapStringKey1 extends VersionedThin
   public int getEntryVersion() {
     return ((entryVersionHighByte << 16) & 0xFF0000) | (entryVersionLowBytes & 0xFFFF);
   }
-  
+
   public long getRegionVersion() {
-    return (((long)regionVersionHighBytes) << 32) | (regionVersionLowBytes & 0x00000000FFFFFFFFL);  
+    return (((long) regionVersionHighBytes) << 32) | (regionVersionLowBytes & 0x00000000FFFFFFFFL);
   }
-  
-  
+
+
   public long getVersionTimeStamp() {
     return getLastModified();
   }
-  
+
   public void setVersionTimeStamp(long time) {
     setLastModified(time);
   }
@@ -326,17 +330,18 @@ public class VersionedThinDiskRegionEntryOffHeapStringKey1 extends VersionedThin
   public VersionSource getMemberID() {
     return this.memberID;
   }
+
   public int getDistributedSystemId() {
     return this.distributedSystemId;
   }
 
   // DO NOT modify this class. It was generated from LeafRegionEntry.cpp
-  
+
   public void setVersions(VersionTag tag) {
     this.memberID = tag.getMemberID();
     int eVersion = tag.getEntryVersion();
-    this.entryVersionLowBytes = (short)(eVersion & 0xffff);
-    this.entryVersionHighByte = (byte)((eVersion & 0xff0000) >> 16);
+    this.entryVersionLowBytes = (short) (eVersion & 0xffff);
+    this.entryVersionHighByte = (byte) ((eVersion & 0xff0000) >> 16);
     this.regionVersionHighBytes = tag.getRegionVersionHighBytes();
     this.regionVersionLowBytes = tag.getRegionVersionLowBytes();
     if (!(tag.isGatewayTag()) && this.distributedSystemId == tag.getDistributedSystemId()) {
@@ -348,11 +353,11 @@ public class VersionedThinDiskRegionEntryOffHeapStringKey1 extends VersionedThin
     } else {
       setVersionTimeStamp(tag.getVersionTimeStamp());
     }
-    this.distributedSystemId = (byte)(tag.getDistributedSystemId() & 0xff);
+    this.distributedSystemId = (byte) (tag.getDistributedSystemId() & 0xff);
   }
 
   public void setMemberID(VersionSource memberID) {
-    this.memberID = memberID; 
+    this.memberID = memberID;
   }
 
   @Override
@@ -361,7 +366,7 @@ public class VersionedThinDiskRegionEntryOffHeapStringKey1 extends VersionedThin
   }
 
   // DO NOT modify this class. It was generated from LeafRegionEntry.cpp
-  
+
   public VersionTag asVersionTag() {
     VersionTag tag = VersionTag.create(memberID);
     tag.setEntryVersion(getEntryVersion());
@@ -371,9 +376,9 @@ public class VersionedThinDiskRegionEntryOffHeapStringKey1 extends VersionedThin
     return tag;
   }
 
-  public void processVersionTag(LocalRegion r, VersionTag tag,
-      boolean isTombstoneFromGII, boolean hasDelta,
-      VersionSource thisVM, InternalDistributedMember sender, boolean checkForConflicts) {
+  public void processVersionTag(LocalRegion r, VersionTag tag, boolean isTombstoneFromGII,
+      boolean hasDelta, VersionSource thisVM, InternalDistributedMember sender,
+      boolean checkForConflicts) {
     basicProcessVersionTag(r, tag, isTombstoneFromGII, hasDelta, thisVM, sender, checkForConflicts);
   }
 
@@ -388,38 +393,41 @@ public class VersionedThinDiskRegionEntryOffHeapStringKey1 extends VersionedThin
   public short getRegionVersionHighBytes() {
     return this.regionVersionHighBytes;
   }
-  
+
   /** get rvv internal low bytes. Used by region entries for transferring to storage */
   public int getRegionVersionLowBytes() {
     return this.regionVersionLowBytes;
   }
 
-  
+
   // DO NOT modify this class. It was generated from LeafRegionEntry.cpp
-  
+
   // key code
 
   private final long bits1;
+
   private int getKeyLength() {
     return (int) (this.bits1 & 0x003fL);
   }
+
   private int getEncoding() {
     // 0 means encoded as char
     // 1 means encoded as bytes that are all <= 0x7f;
     return (int) (this.bits1 >> 6) & 0x03;
   }
+
   @Override
   public Object getKey() {
     int keylen = getKeyLength();
     char[] chars = new char[keylen];
     long tmpBits1 = this.bits1;
     if (getEncoding() == 1) {
-      for (int i=0; i < keylen; i++) {
+      for (int i = 0; i < keylen; i++) {
         tmpBits1 >>= 8;
-      chars[i] = (char) (tmpBits1 & 0x00ff);
+        chars[i] = (char) (tmpBits1 & 0x00ff);
       }
     } else {
-      for (int i=0; i < keylen; i++) {
+      for (int i = 0; i < keylen; i++) {
         tmpBits1 >>= 16;
         chars[i] = (char) (tmpBits1 & 0x00FFff);
       }
@@ -428,16 +436,16 @@ public class VersionedThinDiskRegionEntryOffHeapStringKey1 extends VersionedThin
   }
 
   // DO NOT modify this class. It was generated from LeafRegionEntry.cpp
-  
+
   @Override
   public boolean isKeyEqual(Object k) {
     if (k instanceof String) {
-      String str = (String)k;
+      String str = (String) k;
       int keylen = getKeyLength();
       if (str.length() == keylen) {
         long tmpBits1 = this.bits1;
         if (getEncoding() == 1) {
-          for (int i=0; i < keylen; i++) {
+          for (int i = 0; i < keylen; i++) {
             tmpBits1 >>= 8;
             char c = (char) (tmpBits1 & 0x00ff);
             if (str.charAt(i) != c) {
@@ -445,7 +453,7 @@ public class VersionedThinDiskRegionEntryOffHeapStringKey1 extends VersionedThin
             }
           }
         } else {
-          for (int i=0; i < keylen; i++) {
+          for (int i = 0; i < keylen; i++) {
             tmpBits1 >>= 16;
             char c = (char) (tmpBits1 & 0x00FFff);
             if (str.charAt(i) != c) {
@@ -458,7 +466,7 @@ public class VersionedThinDiskRegionEntryOffHeapStringKey1 extends VersionedThin
     }
     return false;
   }
-  
+
 
   // DO NOT modify this class. It was generated from LeafRegionEntry.cpp
 }


Mime
View raw message