Interface BlockingResultInfo
- All Superinterfaces:
IntermediateResultInfo
- All Known Implementing Classes:
AllToAllBlockingResultInfo,BlockingInputInfo,PointwiseBlockingResultInfo
The blocking result info, which will be used to calculate the vertex parallelism and input infos.
-
Method Summary
Modifier and TypeMethodDescriptionlongReturn the num of bytes produced(numBytesProduced) by the producer.longgetNumBytesProduced(IndexRange partitionIndexRange, IndexRange subpartitionIndexRange) Return the aggregated num of bytes according to the index range for partition and subpartition.Gets subpartition bytes by partition index.voidrecordPartitionInfo(int partitionIndex, ResultPartitionBytes partitionBytes) Record the information of the result partition.voidresetPartitionInfo(int partitionIndex) Reset the information of the result partition.Methods inherited from interface org.apache.flink.runtime.executiongraph.IntermediateResultInfo
getNumPartitions, getNumSubpartitions, getResultId, isBroadcast, isPointwise, isSingleSubpartitionContainsAllData
-
Method Details
-
getNumBytesProduced
long getNumBytesProduced()Return the num of bytes produced(numBytesProduced) by the producer.The difference between numBytesProduced and numBytesOut : numBytesProduced represents the number of bytes actually produced, and numBytesOut represents the number of bytes sent to downstream tasks. In unicast scenarios, these two values should be equal. In broadcast scenarios, numBytesOut should be (N * numBytesProduced), where N refers to the number of subpartitions.
- Returns:
- the num of bytes produced by the producer
-
getNumBytesProduced
Return the aggregated num of bytes according to the index range for partition and subpartition.- Parameters:
partitionIndexRange- range of the index of the consumed partition.subpartitionIndexRange- range of the index of the consumed subpartition.- Returns:
- aggregated bytes according to the index ranges.
-
recordPartitionInfo
Record the information of the result partition.- Parameters:
partitionIndex- the intermediate result partition indexpartitionBytes- theResultPartitionBytesof the partition
-
resetPartitionInfo
void resetPartitionInfo(int partitionIndex) Reset the information of the result partition.- Parameters:
partitionIndex- the intermediate result partition index
-
getSubpartitionBytesByPartitionIndex
Gets subpartition bytes by partition index.- Returns:
- a map with integer keys representing partition indices and long array values representing subpartition bytes.
-