Class SideOutputDataStream<T>
java.lang.Object
org.apache.flink.streaming.api.datastream.DataStream<T>
org.apache.flink.streaming.api.datastream.SideOutputDataStream<T>
- Type Parameters:
T- The type of the elements in this stream.
A
SideOutputDataStream represents a DataStream that contains elements that are
emitted from upstream into a side output with some tag.-
Nested Class Summary
Nested classes/interfaces inherited from class org.apache.flink.streaming.api.datastream.DataStream
DataStream.Collector<T> -
Field Summary
Fields inherited from class org.apache.flink.streaming.api.datastream.DataStream
environment, transformation -
Constructor Summary
ConstructorsConstructorDescriptionSideOutputDataStream(StreamExecutionEnvironment environment, SideOutputTransformation<T> transformation) Creates a newSideOutputDataStreamin the given execution environment. -
Method Summary
Methods inherited from class org.apache.flink.streaming.api.datastream.DataStream
addSink, assignTimestampsAndWatermarks, broadcast, broadcast, clean, coGroup, collectAsync, collectAsync, connect, connect, countWindowAll, countWindowAll, doTransform, executeAndCollect, executeAndCollect, executeAndCollect, executeAndCollect, filter, flatMap, flatMap, forward, fullWindowPartition, getExecutionConfig, getExecutionEnvironment, getId, getMinResources, getParallelism, getPreferredResources, getTransformation, getType, global, join, keyBy, keyBy, keyBy, map, map, partitionCustom, print, print, printToErr, printToErr, process, process, project, rebalance, rescale, setConnectionType, shuffle, sinkTo, sinkTo, transform, transform, union, windowAll, writeToSocket, writeUsingOutputFormat
-
Constructor Details
-
SideOutputDataStream
public SideOutputDataStream(StreamExecutionEnvironment environment, SideOutputTransformation<T> transformation) Creates a newSideOutputDataStreamin the given execution environment.- Parameters:
environment- The StreamExecutionEnvironmenttransformation- The SideOutputTransformation
-
-
Method Details
-
cache
Caches the intermediate result of the transformation. Only support bounded streams and currently only block mode is supported. The cache is generated lazily at the first time the intermediate result is computed. The cache will be clear whenCachedDataStream.invalidate()called or theStreamExecutionEnvironmentclose.- Returns:
- CachedDataStream that can use in later job to reuse the cached intermediate result.
-