Class NettyPartitionRequestListener
java.lang.Object
org.apache.flink.runtime.io.network.netty.NettyPartitionRequestListener
- All Implemented Interfaces:
PartitionRequestListener
Implementation of
PartitionRequestListener for netty partition request.-
Constructor Summary
ConstructorsConstructorDescriptionNettyPartitionRequestListener(ResultPartitionProvider resultPartitionProvider, NetworkSequenceViewReader reader, ResultSubpartitionIndexSet subpartitionIndexSet, ResultPartitionID resultPartitionId) NettyPartitionRequestListener(ResultPartitionProvider resultPartitionProvider, NetworkSequenceViewReader reader, ResultSubpartitionIndexSet subpartitionIndexSet, ResultPartitionID resultPartitionId, long createTimestamp) -
Method Summary
Modifier and TypeMethodDescriptionlongThe creation timestamp of this notifier, it's used to check whether the notifier is timeout.Get the input channel id of the notifier.Get the result partition id of the notifier.Get the view reader of the notifier.voidnotifyPartitionCreated(ResultPartition partition) Notify the partition request listener when the given partition is registered.voidWhen the partition request listener is timeout, it will be notified to sendPartitionNotFoundException.voidRelease this listener.
-
Constructor Details
-
NettyPartitionRequestListener
public NettyPartitionRequestListener(ResultPartitionProvider resultPartitionProvider, NetworkSequenceViewReader reader, ResultSubpartitionIndexSet subpartitionIndexSet, ResultPartitionID resultPartitionId) -
NettyPartitionRequestListener
@VisibleForTesting public NettyPartitionRequestListener(ResultPartitionProvider resultPartitionProvider, NetworkSequenceViewReader reader, ResultSubpartitionIndexSet subpartitionIndexSet, ResultPartitionID resultPartitionId, long createTimestamp)
-
-
Method Details
-
getCreateTimestamp
public long getCreateTimestamp()Description copied from interface:PartitionRequestListenerThe creation timestamp of this notifier, it's used to check whether the notifier is timeout.- Specified by:
getCreateTimestampin interfacePartitionRequestListener- Returns:
- the creation timestamp
-
getResultPartitionId
Description copied from interface:PartitionRequestListenerGet the result partition id of the notifier.- Specified by:
getResultPartitionIdin interfacePartitionRequestListener- Returns:
- the result partition id
-
getViewReader
Description copied from interface:PartitionRequestListenerGet the view reader of the notifier.- Specified by:
getViewReaderin interfacePartitionRequestListener- Returns:
- the view reader
-
getReceiverId
Description copied from interface:PartitionRequestListenerGet the input channel id of the notifier.- Specified by:
getReceiverIdin interfacePartitionRequestListener- Returns:
- the input channel id
-
notifyPartitionCreated
Description copied from interface:PartitionRequestListenerNotify the partition request listener when the given partition is registered.- Specified by:
notifyPartitionCreatedin interfacePartitionRequestListener- Parameters:
partition- The registered partition.- Throws:
IOException
-
notifyPartitionCreatedTimeout
public void notifyPartitionCreatedTimeout()Description copied from interface:PartitionRequestListenerWhen the partition request listener is timeout, it will be notified to sendPartitionNotFoundException.- Specified by:
notifyPartitionCreatedTimeoutin interfacePartitionRequestListener
-
releaseListener
public void releaseListener()Description copied from interface:PartitionRequestListenerRelease this listener.- Specified by:
releaseListenerin interfacePartitionRequestListener
-