Class IterativeStream.ConnectedIterativeStreams<I,F>
- java.lang.Object
-
- org.apache.flink.streaming.api.datastream.ConnectedStreams<I,F>
-
- org.apache.flink.streaming.api.datastream.IterativeStream.ConnectedIterativeStreams<I,F>
-
- Type Parameters:
I- Type of the input of the iterationF- Type of the feedback of the iteration
- Enclosing class:
- IterativeStream<T>
@Deprecated @Public public static class IterativeStream.ConnectedIterativeStreams<I,F> extends ConnectedStreams<I,F>
Deprecated.This method is deprecated since Flink 1.19. The only known use case of this Iteration API comes from Flink ML, which already has its own implementation of iteration and no longer uses this API. If there's any use cases other than Flink ML that needs iteration support, please reach out to dev@flink.apache.org and we can consider making the Flink ML iteration implementation a separate common library.TheIterativeStream.ConnectedIterativeStreamsrepresent a start of an iterative part of a streaming program, where the original input of the iteration and the feedback of the iteration are connected as in aConnectedStreams.The user can distinguish between the two inputs using co-transformation, thus eliminating the need for mapping the inputs and outputs to a common type.
-
-
Field Summary
-
Fields inherited from class org.apache.flink.streaming.api.datastream.ConnectedStreams
environment, inputStream1, inputStream2
-
-
Constructor Summary
Constructors Constructor Description ConnectedIterativeStreams(DataStream<I> input, org.apache.flink.api.common.typeinfo.TypeInformation<F> feedbackType, long waitTime)Deprecated.
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description DataStream<F>closeWith(DataStream<F> feedbackStream)Deprecated.Closes the iteration.ConnectedStreams<I,F>keyBy(int[] keyPositions1, int[] keyPositions2)Deprecated.KeyBy operation for connected data stream.ConnectedStreams<I,F>keyBy(String[] fields1, String[] fields2)Deprecated.KeyBy operation for connected data stream using key expressions.ConnectedStreams<I,F>keyBy(String field1, String field2)Deprecated.KeyBy operation for connected data stream using key expressions.<KEY> ConnectedStreams<I,F>keyBy(org.apache.flink.api.java.functions.KeySelector<I,KEY> keySelector1, org.apache.flink.api.java.functions.KeySelector<F,KEY> keySelector2)Deprecated.KeyBy operation for connected data stream.<KEY> ConnectedStreams<I,F>keyBy(org.apache.flink.api.java.functions.KeySelector<I,KEY> keySelector1, org.apache.flink.api.java.functions.KeySelector<F,KEY> keySelector2, org.apache.flink.api.common.typeinfo.TypeInformation<KEY> keyType)Deprecated.KeyBy operation for connected data stream.-
Methods inherited from class org.apache.flink.streaming.api.datastream.ConnectedStreams
flatMap, flatMap, getExecutionEnvironment, getFirstInput, getSecondInput, getType1, getType2, keyBy, map, map, process, process, process, process, transform, transform
-
-
-
-
Constructor Detail
-
ConnectedIterativeStreams
public ConnectedIterativeStreams(DataStream<I> input, org.apache.flink.api.common.typeinfo.TypeInformation<F> feedbackType, long waitTime)
Deprecated.
-
-
Method Detail
-
closeWith
public DataStream<F> closeWith(DataStream<F> feedbackStream)
Deprecated.Closes the iteration. This method defines the end of the iterative program part that will be fed back to the start of the iteration as the second input in theConnectedStreams.- Parameters:
feedbackStream-DataStreamthat will be used as second input to the iteration head.- Returns:
- The feedback stream.
-
keyBy
public ConnectedStreams<I,F> keyBy(int[] keyPositions1, int[] keyPositions2)
Deprecated.Description copied from class:ConnectedStreamsKeyBy operation for connected data stream. Assigns keys to the elements of input1 and input2 according to keyPositions1 and keyPositions2.- Overrides:
keyByin classConnectedStreams<I,F>- Parameters:
keyPositions1- The fields used to group the first input stream.keyPositions2- The fields used to group the second input stream.- Returns:
- The grouped
ConnectedStreams
-
keyBy
public ConnectedStreams<I,F> keyBy(String field1, String field2)
Deprecated.Description copied from class:ConnectedStreamsKeyBy operation for connected data stream using key expressions. Assigns keys to the elements of input1 and input2 according to field1 and field2. A field expression is either the name of a public field or a getter method with parentheses of theDataStreamS underlying type. A dot can be used to drill down into objects, as in"field1.getInnerField2()".- Overrides:
keyByin classConnectedStreams<I,F>- Parameters:
field1- The grouping expression for the first inputfield2- The grouping expression for the second input- Returns:
- The grouped
ConnectedStreams
-
keyBy
public ConnectedStreams<I,F> keyBy(String[] fields1, String[] fields2)
Deprecated.Description copied from class:ConnectedStreamsKeyBy operation for connected data stream using key expressions. the elements of input1 and input2 according to fields1 and fields2. A field expression is either the name of a public field or a getter method with parentheses of theDataStreamS underlying type. A dot can be used to drill down into objects, as in"field1.getInnerField2()".- Overrides:
keyByin classConnectedStreams<I,F>- Parameters:
fields1- The grouping expressions for the first inputfields2- The grouping expressions for the second input- Returns:
- The grouped
ConnectedStreams
-
keyBy
public <KEY> ConnectedStreams<I,F> keyBy(org.apache.flink.api.java.functions.KeySelector<I,KEY> keySelector1, org.apache.flink.api.java.functions.KeySelector<F,KEY> keySelector2)
Deprecated.Description copied from class:ConnectedStreamsKeyBy operation for connected data stream. Assigns keys to the elements of input1 and input2 using keySelector1 and keySelector2.- Overrides:
keyByin classConnectedStreams<I,F>- Parameters:
keySelector1- TheKeySelectorused for grouping the first inputkeySelector2- TheKeySelectorused for grouping the second input- Returns:
- The partitioned
ConnectedStreams
-
keyBy
public <KEY> ConnectedStreams<I,F> keyBy(org.apache.flink.api.java.functions.KeySelector<I,KEY> keySelector1, org.apache.flink.api.java.functions.KeySelector<F,KEY> keySelector2, org.apache.flink.api.common.typeinfo.TypeInformation<KEY> keyType)
Deprecated.Description copied from class:ConnectedStreamsKeyBy operation for connected data stream. Assigns keys to the elements of input1 and input2 using keySelector1 and keySelector2 with explicit type information for the common key type.- Overrides:
keyByin classConnectedStreams<I,F>- Parameters:
keySelector1- TheKeySelectorused for grouping the first inputkeySelector2- TheKeySelectorused for grouping the second inputkeyType- The type information of the common key type.- Returns:
- The partitioned
ConnectedStreams
-
-