Skip to content

Commit a25e779

Browse files
committed
HBASE-26885 The TRSP should not go on when it get a bogus server name… (#4276)
* HBASE-26885 The TRSP should not go on when it get a bogus server name from AM (cherry picked from commit 1efd8fe)
1 parent 543128d commit a25e779

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

hbase-server/src/main/java/org/apache/hadoop/hbase/master/assignment/TransitRegionStateProcedure.java

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,8 @@
1717
*/
1818
package org.apache.hadoop.hbase.master.assignment;
1919

20+
import static org.apache.hadoop.hbase.master.LoadBalancer.BOGUS_SERVER_NAME;
21+
2022
import edu.umd.cs.findbugs.annotations.Nullable;
2123
import java.io.IOException;
2224
import org.apache.hadoop.hbase.HBaseIOException;
@@ -199,7 +201,7 @@ private void queueAssign(MasterProcedureEnv env, RegionStateNode regionNode)
199201

200202
private void openRegion(MasterProcedureEnv env, RegionStateNode regionNode) throws IOException {
201203
ServerName loc = regionNode.getRegionLocation();
202-
if (loc == null) {
204+
if (loc == null || BOGUS_SERVER_NAME.equals(loc)) {
203205
LOG.warn("No location specified for {}, jump back to state {} to get one", getRegion(),
204206
RegionStateTransitionState.REGION_STATE_TRANSITION_GET_ASSIGN_CANDIDATE);
205207
setNextState(RegionStateTransitionState.REGION_STATE_TRANSITION_GET_ASSIGN_CANDIDATE);

0 commit comments

Comments
 (0)