Class GlobalPartitioner<T>
java.lang.Object
org.apache.flink.streaming.runtime.partitioner.StreamPartitioner<T>
org.apache.flink.streaming.runtime.partitioner.GlobalPartitioner<T>
- Type Parameters:
T- Type of the elements in the Stream being partitioned
- All Implemented Interfaces:
Serializable,ChannelSelector<SerializationDelegate<StreamRecord<T>>>
Partitioner that sends all elements to the downstream operator with subtask ID=0.
- See Also:
-
Field Summary
Fields inherited from class org.apache.flink.streaming.runtime.partitioner.StreamPartitioner
numberOfChannels -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncopy()Defines the behavior of this partitioner, when downstream rescaled during recovery of in-flight data.booleanintselectChannel(SerializationDelegate<StreamRecord<T>> record) Returns the logical channel index, to which the given record should be written.toString()Methods inherited from class org.apache.flink.streaming.runtime.partitioner.StreamPartitioner
disableUnalignedCheckpoints, equals, getUpstreamSubtaskStateMapper, hashCode, isBroadcast, isSupportsUnalignedCheckpoint, setup
-
Constructor Details
-
GlobalPartitioner
public GlobalPartitioner()
-
-
Method Details
-
selectChannel
Description copied from interface:ChannelSelectorReturns the logical channel index, to which the given record should be written. It is illegal to call this method for broadcast channel selectors and this method can remain not implemented in that case (for example by throwingUnsupportedOperationException).- Parameters:
record- the record to determine the output channels for.- Returns:
- an integer number which indicates the index of the output channel through which the record shall be forwarded.
-
copy
- Specified by:
copyin classStreamPartitioner<T>
-
getDownstreamSubtaskStateMapper
Description copied from class:StreamPartitionerDefines the behavior of this partitioner, when downstream rescaled during recovery of in-flight data.- Specified by:
getDownstreamSubtaskStateMapperin classStreamPartitioner<T>
-
isPointwise
public boolean isPointwise()- Specified by:
isPointwisein classStreamPartitioner<T>
-
toString
-