Class ConsumedPartitionGroup
- java.lang.Object
-
- org.apache.flink.runtime.scheduler.strategy.ConsumedPartitionGroup
-
- All Implemented Interfaces:
Iterable<IntermediateResultPartitionID>
public class ConsumedPartitionGroup extends Object implements Iterable<IntermediateResultPartitionID>
Group of consumedIntermediateResultPartitionID
s. One such a group corresponds to oneConsumerVertexGroup
.
-
-
Method Summary
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface java.lang.Iterable
forEach, spliterator
-
-
-
-
Method Detail
-
fromMultiplePartitions
public static ConsumedPartitionGroup fromMultiplePartitions(int numConsumers, List<IntermediateResultPartitionID> resultPartitions, ResultPartitionType resultPartitionType)
-
fromSinglePartition
public static ConsumedPartitionGroup fromSinglePartition(int numConsumers, IntermediateResultPartitionID resultPartition, ResultPartitionType resultPartitionType)
-
iterator
public Iterator<IntermediateResultPartitionID> iterator()
- Specified by:
iterator
in interfaceIterable<IntermediateResultPartitionID>
-
size
public int size()
-
isEmpty
public boolean isEmpty()
-
getNumConsumers
public int getNumConsumers()
In dynamic graph cases, the number of consumers of ConsumedPartitionGroup can be different even if they contain the same IntermediateResultPartition.
-
getFirst
public IntermediateResultPartitionID getFirst()
-
getIntermediateDataSetID
public IntermediateDataSetID getIntermediateDataSetID()
Get the ID of IntermediateDataSet this ConsumedPartitionGroup belongs to.
-
partitionUnfinished
public int partitionUnfinished()
-
partitionFinished
public int partitionFinished()
-
getNumberOfUnfinishedPartitions
public int getNumberOfUnfinishedPartitions()
-
areAllPartitionsFinished
public boolean areAllPartitionsFinished()
-
getResultPartitionType
public ResultPartitionType getResultPartitionType()
-
getConsumerVertexGroup
public ConsumerVertexGroup getConsumerVertexGroup()
-
setConsumerVertexGroup
public void setConsumerVertexGroup(ConsumerVertexGroup consumerVertexGroup)
-
-