Search in sources :

Example 1 with MoveRegionStateData

use of org.apache.hadoop.hbase.shaded.protobuf.generated.MasterProcedureProtos.MoveRegionStateData in project hbase by apache.

the class MoveRegionProcedure method deserializeStateData.

@Override
protected void deserializeStateData(ProcedureStateSerializer serializer) throws IOException {
    super.deserializeStateData(serializer);
    final MoveRegionStateData state = serializer.deserialize(MoveRegionStateData.class);
    // Get it from super class deserialization.
    final RegionInfo regionInfo = getRegion();
    final ServerName sourceServer = ProtobufUtil.toServerName(state.getSourceServer());
    final ServerName destinationServer = state.hasDestinationServer() ? ProtobufUtil.toServerName(state.getDestinationServer()) : null;
    this.plan = new RegionPlan(regionInfo, sourceServer, destinationServer);
}
Also used : MoveRegionStateData(org.apache.hadoop.hbase.shaded.protobuf.generated.MasterProcedureProtos.MoveRegionStateData) RegionPlan(org.apache.hadoop.hbase.master.RegionPlan) ServerName(org.apache.hadoop.hbase.ServerName) RegionInfo(org.apache.hadoop.hbase.client.RegionInfo)

Aggregations

ServerName (org.apache.hadoop.hbase.ServerName)1 RegionInfo (org.apache.hadoop.hbase.client.RegionInfo)1 RegionPlan (org.apache.hadoop.hbase.master.RegionPlan)1 MoveRegionStateData (org.apache.hadoop.hbase.shaded.protobuf.generated.MasterProcedureProtos.MoveRegionStateData)1