hbase-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From te...@apache.org
Subject hbase git commit: HBASE-13800 TestStore#testDeleteExpiredStoreFiles should create unique data/log directory for each call (Stephen Jiang)
Date Fri, 29 May 2015 02:30:39 GMT
Repository: hbase
Updated Branches:
  refs/heads/master 365ddfaf5 -> 63d617a0c


HBASE-13800 TestStore#testDeleteExpiredStoreFiles should create unique data/log directory
for each call (Stephen Jiang)


Project: http://git-wip-us.apache.org/repos/asf/hbase/repo
Commit: http://git-wip-us.apache.org/repos/asf/hbase/commit/63d617a0
Tree: http://git-wip-us.apache.org/repos/asf/hbase/tree/63d617a0
Diff: http://git-wip-us.apache.org/repos/asf/hbase/diff/63d617a0

Branch: refs/heads/master
Commit: 63d617a0ccabd6bc4c921f7b70a3ff3f83a245b1
Parents: 365ddfa
Author: tedyu <yuzhihong@gmail.com>
Authored: Thu May 28 19:30:36 2015 -0700
Committer: tedyu <yuzhihong@gmail.com>
Committed: Thu May 28 19:30:36 2015 -0700

----------------------------------------------------------------------
 .../java/org/apache/hadoop/hbase/regionserver/TestStore.java  | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/hbase/blob/63d617a0/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestStore.java
----------------------------------------------------------------------
diff --git a/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestStore.java
b/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestStore.java
index 3adef9d..a1a58bc 100644
--- a/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestStore.java
+++ b/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestStore.java
@@ -307,7 +307,7 @@ public class TestStore {
     HColumnDescriptor hcd = new HColumnDescriptor(family);
     hcd.setMinVersions(minVersions);
     hcd.setTimeToLive(ttl);
-    init(name.getMethodName(), conf, hcd);
+    init(name.getMethodName() + "-" + minVersions, conf, hcd);
 
     long storeTtl = this.store.getScanInfo().getTtl();
     long sleepTime = storeTtl / storeFileNum;
@@ -347,6 +347,7 @@ public class TestStore {
       edge.incrementTime(sleepTime);
     }
     assertNull(this.store.requestCompaction());
+
     Collection<StoreFile> sfs = this.store.getStorefiles();
     // Assert the last expired file is not removed.
     if (minVersions == 0) {
@@ -354,6 +355,10 @@ public class TestStore {
     }
     long ts = sfs.iterator().next().getReader().getMaxTimestamp();
     assertTrue(ts < (edge.currentTime() - storeTtl));
+
+    for (StoreFile sf : sfs) {
+      sf.closeReader(true);
+    }
   }
 
   @Test


Mime
View raw message