public static RebalanceTaskInfoMap encodeRebalanceTaskInfoMap ( RebalanceTaskInfo stealInfo ) { return RebalanceTaskInfoMap . newBuilder ( ) . setStealerId ( stealInfo . getStealerId ( ) ) . setDonorId ( stealInfo . getDonorId ( ) ) . addAllPerStorePartitionIds ( ProtoUtils . encodeStoreToPartitionsTuple ( stealInfo . getStoreToPartitionIds ( ) ) ) . setInitialCluster ( new ClusterMapper ( ) . writeCluster ( stealInfo . getInitialCluster ( ) ) ) . build ( ) ; }
Given a rebalance - task info convert it into the protobuf equivalent