comnetwork commented on a change in pull request #2055:
URL: https://github.com/apache/hbase/pull/2055#discussion_r454764681



##########
File path: 
hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/wal/AsyncProtobufLogWriter.java
##########
@@ -59,7 +59,7 @@
 
   private final Class<? extends Channel> channelClass;
 
-  private AsyncFSOutput output;
+  private volatile AsyncFSOutput output;

Review comment:
       Yes, you are right, I ignored other `write` methods also not test 
whether `output` is null. The problem here is it is meaningless to call  
`AsyncProtobufLogWriter.getSyncedLength` after `AsyncProtobufLogWriter.close` , 
which indeed occured when  #1970  is applied to branch-2 previously caused by 
problematic state synchronization.
   
   If we do not test whether output is null, we can just leave some comments 
here.




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to