You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hbase.apache.org by zg...@apache.org on 2020/09/17 01:53:04 UTC

[hbase] branch branch-2.2 updated: HBASE-25047 WAL split edits number is negative in RegionServerUI (#2408)

This is an automated email from the ASF dual-hosted git repository.

zghao pushed a commit to branch branch-2.2
in repository https://gitbox.apache.org/repos/asf/hbase.git


The following commit(s) were added to refs/heads/branch-2.2 by this push:
     new d4ff9ab  HBASE-25047 WAL split edits number is negative in RegionServerUI (#2408)
d4ff9ab is described below

commit d4ff9abf1b314ab46711aff7e4b10bc0f865fca8
Author: Joseph295 <51...@qq.com>
AuthorDate: Thu Sep 17 09:38:28 2020 +0800

    HBASE-25047 WAL split edits number is negative in RegionServerUI (#2408)
    
    Signed-off-by: Viraj Jasani <vj...@apache.org>
    Signed-off-by: Duo Zhang <zh...@apache.org>
    Signed-off-by: Guanghao Zhang <zg...@apache.org>
---
 hbase-server/src/main/java/org/apache/hadoop/hbase/wal/WALSplitter.java | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/hbase-server/src/main/java/org/apache/hadoop/hbase/wal/WALSplitter.java b/hbase-server/src/main/java/org/apache/hadoop/hbase/wal/WALSplitter.java
index 84b85f2..63d9a5e 100644
--- a/hbase-server/src/main/java/org/apache/hadoop/hbase/wal/WALSplitter.java
+++ b/hbase-server/src/main/java/org/apache/hadoop/hbase/wal/WALSplitter.java
@@ -294,6 +294,7 @@ public class WALSplitter {
           }
           lastFlushedSequenceIds.put(encodedRegionNameAsStr, lastFlushedSequenceId);
         }
+        editsCount++;
         if (lastFlushedSequenceId >= entry.getKey().getSequenceId()) {
           editsSkipped++;
           continue;
@@ -304,7 +305,6 @@ public class WALSplitter {
           continue;
         }
         entryBuffers.appendEntry(entry);
-        editsCount++;
         int moreWritersFromLastCheck = this.getNumOpenWriters() - numOpenedFilesLastCheck;
         // If sufficient edits have passed, check if we should report progress.
         if (editsCount % interval == 0