Class DataStreamSource<T>
- java.lang.Object
-
- org.apache.flink.streaming.api.datastream.DataStream<T>
-
- org.apache.flink.streaming.api.datastream.SingleOutputStreamOperator<T>
-
- org.apache.flink.streaming.api.datastream.DataStreamSource<T>
-
- Type Parameters:
T
- Type of the elements in the DataStream created from the this source.
@Public public class DataStreamSource<T> extends SingleOutputStreamOperator<T>
The DataStreamSource represents the starting point of a DataStream.
-
-
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.SingleOutputStreamOperator
nonParallel
-
Fields inherited from class org.apache.flink.streaming.api.datastream.DataStream
environment, transformation
-
-
Constructor Summary
Constructors Constructor Description DataStreamSource(SingleOutputStreamOperator<T> operator)
Constructor for "deep" sources that manually set up (one or more) custom configured complex operators.DataStreamSource(StreamExecutionEnvironment environment, org.apache.flink.api.common.typeinfo.TypeInformation<T> outTypeInfo, StreamSource<T,?> operator, boolean isParallel, String sourceName)
DataStreamSource(StreamExecutionEnvironment environment, org.apache.flink.api.common.typeinfo.TypeInformation<T> outTypeInfo, StreamSource<T,?> operator, boolean isParallel, String sourceName, org.apache.flink.api.connector.source.Boundedness boundedness)
The constructor used to create legacy sources.DataStreamSource(StreamExecutionEnvironment environment, org.apache.flink.api.connector.source.Source<T,?,?> source, org.apache.flink.api.common.eventtime.WatermarkStrategy<T> watermarkStrategy, org.apache.flink.api.common.typeinfo.TypeInformation<T> outTypeInfo, String sourceName)
Constructor for new Sources (FLIP-27).
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description DataStreamSource<T>
setParallelism(int parallelism)
Sets the parallelism for this operator.-
Methods inherited from class org.apache.flink.streaming.api.datastream.SingleOutputStreamOperator
cache, disableChaining, enableAsyncState, forceNonParallel, getName, getSideOutput, name, returns, returns, returns, setBufferTimeout, setDescription, setMaxParallelism, setUidHash, slotSharingGroup, slotSharingGroup, startNewChain, uid
-
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 Detail
-
DataStreamSource
public DataStreamSource(StreamExecutionEnvironment environment, org.apache.flink.api.common.typeinfo.TypeInformation<T> outTypeInfo, StreamSource<T,?> operator, boolean isParallel, String sourceName)
-
DataStreamSource
public DataStreamSource(StreamExecutionEnvironment environment, org.apache.flink.api.common.typeinfo.TypeInformation<T> outTypeInfo, StreamSource<T,?> operator, boolean isParallel, String sourceName, org.apache.flink.api.connector.source.Boundedness boundedness)
The constructor used to create legacy sources.
-
DataStreamSource
public DataStreamSource(SingleOutputStreamOperator<T> operator)
Constructor for "deep" sources that manually set up (one or more) custom configured complex operators.
-
DataStreamSource
public DataStreamSource(StreamExecutionEnvironment environment, org.apache.flink.api.connector.source.Source<T,?,?> source, org.apache.flink.api.common.eventtime.WatermarkStrategy<T> watermarkStrategy, org.apache.flink.api.common.typeinfo.TypeInformation<T> outTypeInfo, String sourceName)
Constructor for new Sources (FLIP-27).
-
-
Method Detail
-
setParallelism
public DataStreamSource<T> setParallelism(int parallelism)
Description copied from class:SingleOutputStreamOperator
Sets the parallelism for this operator.- Overrides:
setParallelism
in classSingleOutputStreamOperator<T>
- Parameters:
parallelism
- The parallelism for this operator.- Returns:
- The operator with set parallelism.
-
-