geode-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dschnei...@apache.org
Subject incubator-geode git commit: add testHook methods to compute inVM and onDisk
Date Mon, 08 Aug 2016 23:36:55 GMT
Repository: incubator-geode
Updated Branches:
  refs/heads/feature/GEODE-1714 0644c7959 -> 29576f0f3


add testHook methods to compute inVM and onDisk


Project: http://git-wip-us.apache.org/repos/asf/incubator-geode/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-geode/commit/29576f0f
Tree: http://git-wip-us.apache.org/repos/asf/incubator-geode/tree/29576f0f
Diff: http://git-wip-us.apache.org/repos/asf/incubator-geode/diff/29576f0f

Branch: refs/heads/feature/GEODE-1714
Commit: 29576f0f3de751dfcf99a987342c666b207b81f6
Parents: 0644c79
Author: Darrel Schneider <dschneider@pivotal.io>
Authored: Mon Aug 8 16:36:46 2016 -0700
Committer: Darrel Schneider <dschneider@pivotal.io>
Committed: Mon Aug 8 16:36:46 2016 -0700

----------------------------------------------------------------------
 .../gemfire/internal/cache/LocalRegion.java     | 20 ++++++++++++++++++++
 1 file changed, 20 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/29576f0f/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/LocalRegion.java
----------------------------------------------------------------------
diff --git a/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/LocalRegion.java
b/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/LocalRegion.java
index 46ccd47..73dc5ab 100644
--- a/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/LocalRegion.java
+++ b/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/LocalRegion.java
@@ -12741,4 +12741,24 @@ public class LocalRegion extends AbstractRegion
     
   }
   
+  public int testHookGetValuesInVM() {
+    int result = 0;
+    for (RegionEntry re: getRegionMap().regionEntries()) {
+      if (re.getValueAsToken() == Token.NOT_A_TOKEN) {
+        result++;
+      }
+    }
+    return result;
+  }
+  
+  public int testHookGetValuesOnDisk() {
+    int result = 0;
+    for (RegionEntry re: getRegionMap().regionEntries()) {
+      if (re.getValueAsToken() == null) {
+        result++;
+      }
+    }
+    return result;
+  }
+  
 }


Mime
View raw message