Class JoinedStreams.WithWindow<T1,T2,KEY,W extends Window>
- java.lang.Object
-
- org.apache.flink.streaming.api.datastream.JoinedStreams.WithWindow<T1,T2,KEY,W>
-
- Type Parameters:
T1- Type of the elements from the first inputT2- Type of the elements from the second inputKEY- Type of the key. This must be the same for both inputsW- Type ofWindowon which the join operation works.
- Enclosing class:
- JoinedStreams<T1,T2>
@Public public static class JoinedStreams.WithWindow<T1,T2,KEY,W extends Window> extends Object
A join operation that hasKeySelectorsdefined for both inputs as well as aWindowAssigner.
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedWithWindow(DataStream<T1> input1, DataStream<T2> input2, org.apache.flink.api.java.functions.KeySelector<T1,KEY> keySelector1, org.apache.flink.api.java.functions.KeySelector<T2,KEY> keySelector2, org.apache.flink.api.common.typeinfo.TypeInformation<KEY> keyType, WindowAssigner<? super CoGroupedStreams.TaggedUnion<T1,T2>,W> windowAssigner, Trigger<? super CoGroupedStreams.TaggedUnion<T1,T2>,? super W> trigger, Evictor<? super CoGroupedStreams.TaggedUnion<T1,T2>,? super W> evictor, Duration allowedLateness)protectedWithWindow(DataStream<T1> input1, DataStream<T2> input2, org.apache.flink.api.java.functions.KeySelector<T1,KEY> keySelector1, org.apache.flink.api.java.functions.KeySelector<T2,KEY> keySelector2, org.apache.flink.api.common.typeinfo.TypeInformation<KEY> keyType, WindowAssigner<? super CoGroupedStreams.TaggedUnion<T1,T2>,W> windowAssigner, Trigger<? super CoGroupedStreams.TaggedUnion<T1,T2>,? super W> trigger, Evictor<? super CoGroupedStreams.TaggedUnion<T1,T2>,? super W> evictor, Time allowedLateness)
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description JoinedStreams.WithWindow<T1,T2,KEY,W>allowedLateness(Duration newLateness)Sets the time by which elements are allowed to be late.JoinedStreams.WithWindow<T1,T2,KEY,W>allowedLateness(Time newLateness)Deprecated.<T> DataStream<T>apply(org.apache.flink.api.common.functions.FlatJoinFunction<T1,T2,T> function)Completes the join operation with the user function that is executed for each combination of elements with the same key in a window.<T> DataStream<T>apply(org.apache.flink.api.common.functions.FlatJoinFunction<T1,T2,T> function, org.apache.flink.api.common.typeinfo.TypeInformation<T> resultType)Completes the join operation with the user function that is executed for each combination of elements with the same key in a window.<T> DataStream<T>apply(org.apache.flink.api.common.functions.JoinFunction<T1,T2,T> function)Completes the join operation with the user function that is executed for each combination of elements with the same key in a window.<T> DataStream<T>apply(org.apache.flink.api.common.functions.JoinFunction<T1,T2,T> function, org.apache.flink.api.common.typeinfo.TypeInformation<T> resultType)Completes the join operation with the user function that is executed for each combination of elements with the same key in a window.JoinedStreams.WithWindow<T1,T2,KEY,W>evictor(Evictor<? super CoGroupedStreams.TaggedUnion<T1,T2>,? super W> newEvictor)Sets theEvictorthat should be used to evict elements from a window before emission.JoinedStreams.WithWindow<T1,T2,KEY,W>trigger(Trigger<? super CoGroupedStreams.TaggedUnion<T1,T2>,? super W> newTrigger)Sets theTriggerthat should be used to trigger window emission.<T> SingleOutputStreamOperator<T>with(org.apache.flink.api.common.functions.FlatJoinFunction<T1,T2,T> function)Deprecated.This method will be removed once theapply(FlatJoinFunction)method is fixed in the next major version of Flink (2.0).<T> SingleOutputStreamOperator<T>with(org.apache.flink.api.common.functions.FlatJoinFunction<T1,T2,T> function, org.apache.flink.api.common.typeinfo.TypeInformation<T> resultType)Deprecated.This method will be replaced byapply(FlatJoinFunction, TypeInformation)in Flink 2.0.<T> SingleOutputStreamOperator<T>with(org.apache.flink.api.common.functions.JoinFunction<T1,T2,T> function)Deprecated.This method will be removed once theapply(JoinFunction)method is fixed in the next major version of Flink (2.0).<T> SingleOutputStreamOperator<T>with(org.apache.flink.api.common.functions.JoinFunction<T1,T2,T> function, org.apache.flink.api.common.typeinfo.TypeInformation<T> resultType)Deprecated.This method will be removed once theapply(JoinFunction, TypeInformation)method is fixed in the next major version of Flink (2.0).
-
-
-
Constructor Detail
-
WithWindow
@Deprecated @PublicEvolving protected WithWindow(DataStream<T1> input1, DataStream<T2> input2, org.apache.flink.api.java.functions.KeySelector<T1,KEY> keySelector1, org.apache.flink.api.java.functions.KeySelector<T2,KEY> keySelector2, org.apache.flink.api.common.typeinfo.TypeInformation<KEY> keyType, WindowAssigner<? super CoGroupedStreams.TaggedUnion<T1,T2>,W> windowAssigner, Trigger<? super CoGroupedStreams.TaggedUnion<T1,T2>,? super W> trigger, Evictor<? super CoGroupedStreams.TaggedUnion<T1,T2>,? super W> evictor, @Nullable Time allowedLateness)
-
WithWindow
@PublicEvolving protected WithWindow(DataStream<T1> input1, DataStream<T2> input2, org.apache.flink.api.java.functions.KeySelector<T1,KEY> keySelector1, org.apache.flink.api.java.functions.KeySelector<T2,KEY> keySelector2, org.apache.flink.api.common.typeinfo.TypeInformation<KEY> keyType, WindowAssigner<? super CoGroupedStreams.TaggedUnion<T1,T2>,W> windowAssigner, Trigger<? super CoGroupedStreams.TaggedUnion<T1,T2>,? super W> trigger, Evictor<? super CoGroupedStreams.TaggedUnion<T1,T2>,? super W> evictor, @Nullable Duration allowedLateness)
-
-
Method Detail
-
trigger
@PublicEvolving public JoinedStreams.WithWindow<T1,T2,KEY,W> trigger(Trigger<? super CoGroupedStreams.TaggedUnion<T1,T2>,? super W> newTrigger)
Sets theTriggerthat should be used to trigger window emission.
-
evictor
@PublicEvolving public JoinedStreams.WithWindow<T1,T2,KEY,W> evictor(Evictor<? super CoGroupedStreams.TaggedUnion<T1,T2>,? super W> newEvictor)
Sets theEvictorthat should be used to evict elements from a window before emission.Note: When using an evictor window performance will degrade significantly, since pre-aggregation of window results cannot be used.
-
allowedLateness
@Deprecated @PublicEvolving public JoinedStreams.WithWindow<T1,T2,KEY,W> allowedLateness(@Nullable Time newLateness)
Deprecated.Sets the time by which elements are allowed to be late.- See Also:
WindowedStream.allowedLateness(Duration)
-
allowedLateness
@PublicEvolving public JoinedStreams.WithWindow<T1,T2,KEY,W> allowedLateness(@Nullable Duration newLateness)
Sets the time by which elements are allowed to be late.- See Also:
WindowedStream.allowedLateness(Duration)
-
apply
public <T> DataStream<T> apply(org.apache.flink.api.common.functions.JoinFunction<T1,T2,T> function)
Completes the join operation with the user function that is executed for each combination of elements with the same key in a window.Note: This method's return type does not support setting an operator-specific parallelism. Due to binary backwards compatibility, this cannot be altered. Use the
with(JoinFunction)method to set an operator-specific parallelism.
-
with
@PublicEvolving @Deprecated public <T> SingleOutputStreamOperator<T> with(org.apache.flink.api.common.functions.JoinFunction<T1,T2,T> function)
Deprecated.This method will be removed once theapply(JoinFunction)method is fixed in the next major version of Flink (2.0).Completes the join operation with the user function that is executed for each combination of elements with the same key in a window.Note: This is a temporary workaround while the
apply(JoinFunction)method has the wrong return type and hence does not allow one to set an operator-specific parallelism
-
apply
public <T> DataStream<T> apply(org.apache.flink.api.common.functions.FlatJoinFunction<T1,T2,T> function, org.apache.flink.api.common.typeinfo.TypeInformation<T> resultType)
Completes the join operation with the user function that is executed for each combination of elements with the same key in a window.Note: This method's return type does not support setting an operator-specific parallelism. Due to binary backwards compatibility, this cannot be altered. Use the
with(JoinFunction, TypeInformation), method to set an operator-specific parallelism.
-
with
@PublicEvolving @Deprecated public <T> SingleOutputStreamOperator<T> with(org.apache.flink.api.common.functions.FlatJoinFunction<T1,T2,T> function, org.apache.flink.api.common.typeinfo.TypeInformation<T> resultType)
Deprecated.This method will be replaced byapply(FlatJoinFunction, TypeInformation)in Flink 2.0. So use theapply(FlatJoinFunction, TypeInformation)in the future.Completes the join operation with the user function that is executed for each combination of elements with the same key in a window.Note: This is a temporary workaround while the
apply(JoinFunction, TypeInformation)method has the wrong return type and hence does not allow one to set an operator-specific parallelism
-
apply
public <T> DataStream<T> apply(org.apache.flink.api.common.functions.FlatJoinFunction<T1,T2,T> function)
Completes the join operation with the user function that is executed for each combination of elements with the same key in a window.Note: This method's return type does not support setting an operator-specific parallelism. Due to binary backwards compatibility, this cannot be altered. Use the
with(FlatJoinFunction), method to set an operator-specific parallelism.
-
with
@PublicEvolving @Deprecated public <T> SingleOutputStreamOperator<T> with(org.apache.flink.api.common.functions.FlatJoinFunction<T1,T2,T> function)
Deprecated.This method will be removed once theapply(FlatJoinFunction)method is fixed in the next major version of Flink (2.0).Completes the join operation with the user function that is executed for each combination of elements with the same key in a window.Note: This is a temporary workaround while the
apply(FlatJoinFunction)method has the wrong return type and hence does not allow one to set an operator-specific parallelism.
-
apply
public <T> DataStream<T> apply(org.apache.flink.api.common.functions.JoinFunction<T1,T2,T> function, org.apache.flink.api.common.typeinfo.TypeInformation<T> resultType)
Completes the join operation with the user function that is executed for each combination of elements with the same key in a window.Note: This method's return type does not support setting an operator-specific parallelism. Due to binary backwards compatibility, this cannot be altered. Use the
with(JoinFunction, TypeInformation), method to set an operator-specific parallelism.
-
with
@PublicEvolving @Deprecated public <T> SingleOutputStreamOperator<T> with(org.apache.flink.api.common.functions.JoinFunction<T1,T2,T> function, org.apache.flink.api.common.typeinfo.TypeInformation<T> resultType)
Deprecated.This method will be removed once theapply(JoinFunction, TypeInformation)method is fixed in the next major version of Flink (2.0).Completes the join operation with the user function that is executed for each combination of elements with the same key in a window.Note: This is a temporary workaround while the
apply(FlatJoinFunction, TypeInformation)method has the wrong return type and hence does not allow one to set an operator-specific parallelism
-
-