@Override
  public MasterProtos.UnassignsResponse unassigns(RpcController controller,
    MasterProtos.UnassignsRequest request) throws ServiceException {
    checkMasterProcedureExecutor();
    final ProcedureExecutor<MasterProcedureEnv> pe = server.getMasterProcedureExecutor();
    final AssignmentManager am = server.getAssignmentManager();
    MasterProtos.UnassignsResponse.Builder responseBuilder =
      MasterProtos.UnassignsResponse.newBuilder();
    final boolean override = request.getOverride();
    final boolean force = request.getForce();
    LOG.info("{} unassigns, override={}", server.getClientIdAuditPrefix(), override);
    for (HBaseProtos.RegionSpecifier rs : request.getRegionList()) {
      final RegionInfo info = getRegionInfo(rs);
      if (info == null) {
        LOG.info("Unknown region {}", rs);
        continue;
      }
      responseBuilder
        .addPid(Optional.ofNullable(am.createOneUnassignProcedure(info, override, force))
          .map(pe::submitProcedure).orElse(Procedure.NO_PROC_ID));
    }
    return responseBuilder.build();
  }
A 'raw' version of unassign that does bulk and can skirt Master state checks if override is
set; i.e. unassigns can be forced during Master startup or if RegionState is unclean. Used by
HBCK2.
hbase-server/src/main/java/org/apache/hadoop/hbase/master/MasterRpcServices.java