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:29:37 GMT
Repository: hbase
Updated Branches:
  refs/heads/branch-1 4545420d6 -> 423499fbf


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/423499fb
Tree: http://git-wip-us.apache.org/repos/asf/hbase/tree/423499fb
Diff: http://git-wip-us.apache.org/repos/asf/hbase/diff/423499fb

Branch: refs/heads/branch-1
Commit: 423499fbfba5c776b456fbf9cd3762428e1db3ba
Parents: 4545420
Author: tedyu <yuzhihong@gmail.com>
Authored: Thu May 28 19:29:35 2015 -0700
Committer: tedyu <yuzhihong@gmail.com>
Committed: Thu May 28 19:29:35 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/423499fb/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 4849efb..125bfa8 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
@@ -304,7 +304,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;
@@ -344,6 +344,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) {
@@ -351,6 +352,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