.build().toByteArray()));
}
public static CustomShuffleEdgeManagerConfig fromUserPayload(
UserPayload payload) throws InvalidProtocolBufferException {
ShuffleEdgeManagerConfigPayloadProto proto =
ShuffleEdgeManagerConfigPayloadProto.parseFrom(ByteString.copyFrom(payload.getPayload()));
return new CustomShuffleEdgeManagerConfig(
proto.getNumSourceTaskOutputs(),
proto.getNumDestinationTasks(),
proto.getNumSourceTasks(),
proto.getBasePartitionRange(),
proto.getRemainderRangeForLastShuffler());
}