hbase-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From apurt...@apache.org
Subject [2/3] hbase git commit: HBASE-11979 Compaction progress reporting is wrong (Esteban Gutierrez)
Date Tue, 09 Dec 2014 21:00:35 GMT
HBASE-11979 Compaction progress reporting is wrong (Esteban Gutierrez)


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

Branch: refs/heads/branch-1
Commit: d4c94a409aee953fcb533cd895d37dca38bb79c7
Parents: 1c99261
Author: Andrew Purtell <apurtell@apache.org>
Authored: Tue Dec 9 12:46:35 2014 -0800
Committer: Andrew Purtell <apurtell@apache.org>
Committed: Tue Dec 9 12:46:46 2014 -0800

----------------------------------------------------------------------
 .../hadoop/hbase/regionserver/compactions/Compactor.java     | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/hbase/blob/d4c94a40/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/compactions/Compactor.java
----------------------------------------------------------------------
diff --git a/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/compactions/Compactor.java
b/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/compactions/Compactor.java
index 2ddc06a..4b62cad 100644
--- a/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/compactions/Compactor.java
+++ b/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/compactions/Compactor.java
@@ -126,10 +126,10 @@ public abstract class Compactor {
         LOG.warn("Null reader for " + file.getPath());
         continue;
       }
-      // NOTE: getFilterEntries could cause under-sized blooms if the user
-      // switches bloom type (e.g. from ROW to ROWCOL)
-      long keyCount = (r.getBloomFilterType() == store.getFamily().getBloomFilterType())
-          ? r.getFilterEntries() : r.getEntries();
+      // NOTE: use getEntries when compacting instead of getFilterEntries, otherwise under-sized
+      // blooms can cause progress to be miscalculated or if the user switches bloom
+      // type (e.g. from ROW to ROWCOL)
+      long keyCount = r.getEntries();
       fd.maxKeyCount += keyCount;
       // calculate the latest MVCC readpoint in any of the involved store files
       Map<byte[], byte[]> fileInfo = r.loadFileInfo();


Mime
View raw message