Class NoOpTimestampsAndWatermarks<T>
java.lang.Object
org.apache.flink.streaming.api.operators.source.NoOpTimestampsAndWatermarks<T>
- Type Parameters:
T- The type of the emitted records.
- All Implemented Interfaces:
TimestampsAndWatermarks<T>
@Internal
public class NoOpTimestampsAndWatermarks<T>
extends Object
implements TimestampsAndWatermarks<T>
An implementation of
TimestampsAndWatermarks where all watermarking/event-time operations
are no-ops. This should be used in execution contexts where no watermarks are needed, for example
in BATCH execution mode.-
Nested Class Summary
Nested classes/interfaces inherited from interface org.apache.flink.streaming.api.operators.source.TimestampsAndWatermarks
TimestampsAndWatermarks.TimestampsAndWatermarksContextProvider, TimestampsAndWatermarks.WatermarkUpdateListener -
Constructor Summary
ConstructorsConstructorDescriptionNoOpTimestampsAndWatermarks(org.apache.flink.api.common.eventtime.TimestampAssigner<T> timestamps) Creates a newNoOpTimestampsAndWatermarkswith the given TimestampAssigner. -
Method Summary
Modifier and TypeMethodDescriptionorg.apache.flink.api.connector.source.ReaderOutput<T>createMainOutput(PushingAsyncDataInput.DataOutput<T> output, TimestampsAndWatermarks.WatermarkUpdateListener watermarkEmitted) Creates the ReaderOutput for the source reader, than internally runs the timestamp extraction and watermark generation.voidemitImmediateWatermark(long wallClockTimestamp) Emit a watermark immediately.voidpauseOrResumeSplits(Collection<String> splitsToPause, Collection<String> splitsToResume) voidStarts emitting periodic watermarks, if this implementation produces watermarks, and if periodic watermarks are configured.voidStops emitting periodic watermarks.
-
Constructor Details
-
NoOpTimestampsAndWatermarks
public NoOpTimestampsAndWatermarks(org.apache.flink.api.common.eventtime.TimestampAssigner<T> timestamps) Creates a newNoOpTimestampsAndWatermarkswith the given TimestampAssigner.
-
-
Method Details
-
createMainOutput
public org.apache.flink.api.connector.source.ReaderOutput<T> createMainOutput(PushingAsyncDataInput.DataOutput<T> output, TimestampsAndWatermarks.WatermarkUpdateListener watermarkEmitted) Description copied from interface:TimestampsAndWatermarksCreates the ReaderOutput for the source reader, than internally runs the timestamp extraction and watermark generation.- Specified by:
createMainOutputin interfaceTimestampsAndWatermarks<T>
-
startPeriodicWatermarkEmits
public void startPeriodicWatermarkEmits()Description copied from interface:TimestampsAndWatermarksStarts emitting periodic watermarks, if this implementation produces watermarks, and if periodic watermarks are configured.Periodic watermarks are produced by periodically calling the
WatermarkGenerator.onPeriodicEmit(WatermarkOutput)method of the underlying Watermark Generators.- Specified by:
startPeriodicWatermarkEmitsin interfaceTimestampsAndWatermarks<T>
-
stopPeriodicWatermarkEmits
public void stopPeriodicWatermarkEmits()Description copied from interface:TimestampsAndWatermarksStops emitting periodic watermarks.- Specified by:
stopPeriodicWatermarkEmitsin interfaceTimestampsAndWatermarks<T>
-
emitImmediateWatermark
public void emitImmediateWatermark(long wallClockTimestamp) Description copied from interface:TimestampsAndWatermarksEmit a watermark immediately.- Specified by:
emitImmediateWatermarkin interfaceTimestampsAndWatermarks<T>
-
pauseOrResumeSplits
public void pauseOrResumeSplits(Collection<String> splitsToPause, Collection<String> splitsToResume) - Specified by:
pauseOrResumeSplitsin interfaceTimestampsAndWatermarks<T>
-