Package org.apache.flink.runtime.shuffle
Class NettyShuffleDescriptor
- java.lang.Object
-
- org.apache.flink.runtime.shuffle.NettyShuffleDescriptor
-
- All Implemented Interfaces:
Serializable,ShuffleDescriptor
public class NettyShuffleDescriptor extends Object implements ShuffleDescriptor
Default implementation ofShuffleDescriptorforNettyShuffleMaster.- See Also:
- Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classNettyShuffleDescriptor.LocalExecutionPartitionConnectionInfoLocal partition connection information.static classNettyShuffleDescriptor.NetworkPartitionConnectionInfoRemote partition connection information with index to query partition.static interfaceNettyShuffleDescriptor.PartitionConnectionInfoInformation for connection to partition producer for shuffle exchange.
-
Constructor Summary
Constructors Constructor Description NettyShuffleDescriptor(ResourceID producerLocation, NettyShuffleDescriptor.PartitionConnectionInfo partitionConnectionInfo, ResultPartitionID resultPartitionID)NettyShuffleDescriptor(ResourceID producerLocation, NettyShuffleDescriptor.PartitionConnectionInfo partitionConnectionInfo, ResultPartitionID resultPartitionID, List<TierShuffleDescriptor> tierShuffleDescriptors)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ConnectionIDgetConnectionId()ResultPartitionIDgetResultPartitionID()List<TierShuffleDescriptor>getTierShuffleDescriptors()booleanisLocalTo(ResourceID consumerLocation)Optional<ResourceID>storesLocalResourcesOn()Returns the location of the producing task executor if the partition occupies local resources there.-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.apache.flink.runtime.shuffle.ShuffleDescriptor
isUnknown
-
-
-
-
Constructor Detail
-
NettyShuffleDescriptor
public NettyShuffleDescriptor(ResourceID producerLocation, NettyShuffleDescriptor.PartitionConnectionInfo partitionConnectionInfo, ResultPartitionID resultPartitionID)
-
NettyShuffleDescriptor
public NettyShuffleDescriptor(ResourceID producerLocation, NettyShuffleDescriptor.PartitionConnectionInfo partitionConnectionInfo, ResultPartitionID resultPartitionID, @Nullable List<TierShuffleDescriptor> tierShuffleDescriptors)
-
-
Method Detail
-
getConnectionId
public ConnectionID getConnectionId()
-
getResultPartitionID
public ResultPartitionID getResultPartitionID()
- Specified by:
getResultPartitionIDin interfaceShuffleDescriptor
-
storesLocalResourcesOn
public Optional<ResourceID> storesLocalResourcesOn()
Description copied from interface:ShuffleDescriptorReturns the location of the producing task executor if the partition occupies local resources there.Indicates that this partition occupies local resources in the producing task executor. Such partition requires that the task executor is running and being connected to be able to consume the produced data. This is mostly relevant for the batch jobs and blocking result partitions which can outlive the producer lifetime and be released externally.
ShuffleEnvironment.releasePartitionsLocally(Collection)can be used to release such kind of partitions locally.- Specified by:
storesLocalResourcesOnin interfaceShuffleDescriptor- Returns:
- the resource id of the producing task executor if the partition occupies local resources there
-
isLocalTo
public boolean isLocalTo(ResourceID consumerLocation)
-
getTierShuffleDescriptors
@Nullable public List<TierShuffleDescriptor> getTierShuffleDescriptors()
-
-