Repository: hbase Updated Branches: refs/heads/branch-2 27e2c8c86 -> 063eefe3b
HBASE-20634 Reopen region while server crash can cause the procedure to be stuck; ADDENDUM Project: http://git-wip-us.apache.org/repos/asf/hbase/repo Commit: http://git-wip-us.apache.org/repos/asf/hbase/commit/063eefe3 Tree: http://git-wip-us.apache.org/repos/asf/hbase/tree/063eefe3 Diff: http://git-wip-us.apache.org/repos/asf/hbase/diff/063eefe3 Branch: refs/heads/branch-2 Commit: 063eefe3b0eed3744a840a46e3b3aa5cef5e32f6 Parents: 27e2c8c Author: Michael Stack <st...@apache.org> Authored: Mon Jun 4 12:38:56 2018 -0700 Committer: Michael Stack <st...@apache.org> Committed: Mon Jun 4 12:38:56 2018 -0700 ---------------------------------------------------------------------- .../hbase/master/replication/RefreshPeerProcedure.java | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/hbase/blob/063eefe3/hbase-server/src/main/java/org/apache/hadoop/hbase/master/replication/RefreshPeerProcedure.java ---------------------------------------------------------------------- diff --git a/hbase-server/src/main/java/org/apache/hadoop/hbase/master/replication/RefreshPeerProcedure.java b/hbase-server/src/main/java/org/apache/hadoop/hbase/master/replication/RefreshPeerProcedure.java index ba9bcdc..10e16e9 100644 --- a/hbase-server/src/main/java/org/apache/hadoop/hbase/master/replication/RefreshPeerProcedure.java +++ b/hbase-server/src/main/java/org/apache/hadoop/hbase/master/replication/RefreshPeerProcedure.java @@ -22,6 +22,7 @@ import org.apache.hadoop.hbase.ServerName; import org.apache.hadoop.hbase.master.procedure.MasterProcedureEnv; import org.apache.hadoop.hbase.master.procedure.PeerProcedureInterface; import org.apache.hadoop.hbase.master.procedure.RSProcedureDispatcher.ServerOperation; +import org.apache.hadoop.hbase.procedure2.FailedRemoteDispatchException; import org.apache.hadoop.hbase.procedure2.Procedure; import org.apache.hadoop.hbase.procedure2.ProcedureEvent; import org.apache.hadoop.hbase.procedure2.ProcedureStateSerializer; @@ -166,10 +167,12 @@ public class RefreshPeerProcedure extends Procedure<MasterProcedureEnv> // retry dispatched = false; } - if (!env.getRemoteDispatcher().addOperationToNode(targetServer, this)) { + try { + env.getRemoteDispatcher().addOperationToNode(targetServer, this); + } catch (FailedRemoteDispatchException frde) { LOG.info("Can not add remote operation for refreshing peer {} for {} to {}, " + - "this usually because the server is already dead, " + - "give up and mark the procedure as complete", peerId, type, targetServer); + "this is usually because the server is already dead, " + + "give up and mark the procedure as complete", peerId, type, targetServer, frde); return null; } dispatched = true;