@Override
  protected void serializeStateData(ProcedureStateSerializer serializer) throws IOException {
    UnassignRegionStateData.Builder state =
      UnassignRegionStateData.newBuilder().setTransitionState(getTransitionState())
        .setHostingServer(ProtobufUtil.toServerName(this.hostingServer))
        .setRegionInfo(ProtobufUtil.toRegionInfo(getRegionInfo()));
    if (this.destinationServer != null) {
      state.setDestinationServer(ProtobufUtil.toServerName(destinationServer));
    }
    if (removeAfterUnassigning) {
      state.setRemoveAfterUnassigning(true);
    }
    if (getAttempt() > 0) {
      state.setAttempt(getAttempt());
    }
    serializer.serialize(state.build());
  }
Leave here only for checking if we can successfully start the master.
@deprecated Do not use any more.
@see TransitRegionStateProcedure
hbase-server/src/main/java/org/apache/hadoop/hbase/master/assignment/UnassignProcedure.java