T - The type of the input elements and the feedback elements.@Internal
public class FeedbackTransformation<T>
extends org.apache.flink.api.dag.Transformation<T>
This is different from how iterations work in batch processing. Once a feedback point is
defined you can connect one or several Transformations as a feedback edges. Operations
downstream from the feedback point will receive elements from the input of this feedback point
and from the feedback edges.
Both the partitioning of the input and the feedback edges is preserved. They can also have
differing partitioning strategies. This requires, however, that the parallelism of the feedback
Transformations must match the parallelism of the input Transformation.
The type of the input Transformation and the feedback Transformation must
match.
| Constructor and Description |
|---|
FeedbackTransformation(org.apache.flink.api.dag.Transformation<T> input,
Long waitTime)
Creates a new
FeedbackTransformation from the given input. |
| Modifier and Type | Method and Description |
|---|---|
void |
addFeedbackEdge(org.apache.flink.api.dag.Transformation<T> transform)
Adds a feedback edge.
|
List<org.apache.flink.api.dag.Transformation<T>> |
getFeedbackEdges()
Returns the list of feedback
Transformations. |
List<org.apache.flink.api.dag.Transformation<?>> |
getInputs() |
protected List<org.apache.flink.api.dag.Transformation<?>> |
getTransitivePredecessorsInternal() |
Long |
getWaitTime()
Returns the wait time.
|
declareManagedMemoryUseCaseAtOperatorScope, declareManagedMemoryUseCaseAtSlotScope, equals, getBufferTimeout, getCoLocationGroupKey, getDescription, getId, getManagedMemoryOperatorScopeUseCaseWeights, getManagedMemorySlotScopeUseCases, getMaxParallelism, getMinResources, getName, getNewNodeId, getOutputType, getParallelism, getPreferredResources, getSlotSharingGroup, getTransitivePredecessors, getUid, getUserProvidedNodeHash, hashCode, isParallelismConfigured, setBufferTimeout, setCoLocationGroupKey, setDescription, setMaxParallelism, setName, setOutputType, setParallelism, setParallelism, setResources, setSlotSharingGroup, setSlotSharingGroup, setUid, setUidHash, toString, updateManagedMemoryStateBackendUseCasepublic FeedbackTransformation(org.apache.flink.api.dag.Transformation<T> input, Long waitTime)
FeedbackTransformation from the given input.input - The input TransformationwaitTime - The wait time of the feedback operator. After the time expires the operation
will close and not receive any more feedback elements.public void addFeedbackEdge(org.apache.flink.api.dag.Transformation<T> transform)
Transformation must match the
parallelism of the input Transformation of this FeedbackTransformationtransform - The new feedback Transformation.public List<org.apache.flink.api.dag.Transformation<T>> getFeedbackEdges()
Transformations.public Long getWaitTime()
protected List<org.apache.flink.api.dag.Transformation<?>> getTransitivePredecessorsInternal()
getTransitivePredecessorsInternal in class org.apache.flink.api.dag.Transformation<T>Copyright © 2014–2025 The Apache Software Foundation. All rights reserved.