hbase-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ramkris...@apache.org
Subject [hbase] branch master updated: HBASE-24713 RS startup with FSHLog throws NPE after HBASE-21751 (#2125)
Date Mon, 03 Aug 2020 04:35:11 GMT
This is an automated email from the ASF dual-hosted git repository.

ramkrishna pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/hbase.git


The following commit(s) were added to refs/heads/master by this push:
     new 9a1bad8  HBASE-24713 RS startup with FSHLog throws NPE after HBASE-21751 (#2125)
9a1bad8 is described below

commit 9a1bad84bf44cc737926c56592a485c606d63529
Author: gkanade <gaurav.kanade@gmail.com>
AuthorDate: Mon Aug 3 10:04:55 2020 +0530

    HBASE-24713 RS startup with FSHLog throws NPE after HBASE-21751 (#2125)
    
    * null check for writer if not initialized yet during syncrunner run
    
    * Revert "null check for writer if not initialized yet during syncrunner run"
    
    This reverts commit 72932ad0df32859c9492b8f313c4a79a7e85bfd0.
    
    * Writer check while trying to attain safe point
    Signed-off-by: Anoop Sam John <anoopsamjohn@apache.com>
    Signed-off-by: Viraj Jasani <vjasani@apache.org>
    Signed-off-by: Ramkrishna <ramkrishna@apache.org>
---
 .../src/main/java/org/apache/hadoop/hbase/regionserver/wal/FSHLog.java  | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/wal/FSHLog.java
b/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/wal/FSHLog.java
index 276902e..63f4029 100644
--- a/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/wal/FSHLog.java
+++ b/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/wal/FSHLog.java
@@ -329,7 +329,7 @@ public class FSHLog extends AbstractFSWAL<Writer> {
     SyncFuture syncFuture = null;
     SafePointZigZagLatch zigzagLatch = null;
     long sequence = -1L;
-    if (this.ringBufferEventHandler != null) {
+    if (this.writer != null && this.ringBufferEventHandler != null) {
       // Get sequence first to avoid dead lock when ring buffer is full
       // Considering below sequence
       // 1. replaceWriter is called and zigzagLatch is initialized


Mime
View raw message