public class TestScanTableSourceWithWatermarkPushDown extends Object implements ScanTableSource, SupportsWatermarkPushDown
SupportsWatermarkPushDown
.
For simplicity, the deprecated source function method is used to create the source.
ScanTableSource.ScanContext, ScanTableSource.ScanRuntimeProvider
DynamicTableSource.Context, DynamicTableSource.DataStructureConverter
Constructor and Description |
---|
TestScanTableSourceWithWatermarkPushDown() |
Modifier and Type | Method and Description |
---|---|
void |
applyWatermark(WatermarkStrategy<RowData> watermarkStrategy)
Provides a
WatermarkStrategy which defines how to generate Watermark s in the
stream source. |
String |
asSummaryString()
Returns a string that summarizes this source for printing to a console or log.
|
DynamicTableSource |
copy()
Creates a copy of this instance during planning.
|
ChangelogMode |
getChangelogMode()
Returns the set of changes that the planner can expect during runtime.
|
ScanTableSource.ScanRuntimeProvider |
getScanRuntimeProvider(ScanTableSource.ScanContext runtimeProviderContext)
Returns a provider of runtime implementation for reading the data.
|
public TestScanTableSourceWithWatermarkPushDown()
public void applyWatermark(WatermarkStrategy<RowData> watermarkStrategy)
SupportsWatermarkPushDown
WatermarkStrategy
which defines how to generate Watermark
s in the
stream source.
The WatermarkStrategy
is a builder/factory for the actual runtime implementation
consisting of TimestampAssigner
(assigns the event-time timestamps to each record)
and the WatermarkGenerator
(generates the watermarks).
Note: If necessary, the watermark strategy will contain required computed column
expressions and consider metadata columns (if SupportsReadingMetadata
is
implemented).
applyWatermark
in interface SupportsWatermarkPushDown
public DynamicTableSource copy()
DynamicTableSource
copy
in interface DynamicTableSource
public String asSummaryString()
DynamicTableSource
asSummaryString
in interface DynamicTableSource
public ChangelogMode getChangelogMode()
ScanTableSource
getChangelogMode
in interface ScanTableSource
RowKind
public ScanTableSource.ScanRuntimeProvider getScanRuntimeProvider(ScanTableSource.ScanContext runtimeProviderContext)
ScanTableSource
There might exist different interfaces for runtime implementation which is why ScanTableSource.ScanRuntimeProvider
serves as the base interface. Concrete ScanTableSource.ScanRuntimeProvider
interfaces might be located in other Flink modules.
Independent of the provider interface, the table runtime expects that a source
implementation emits internal data structures (see RowData
for more information).
The given ScanTableSource.ScanContext
offers utilities by the planner for creating runtime
implementation with minimal dependencies to internal data structures.
SourceProvider
is the recommended core interface. SourceFunctionProvider
in flink-table-api-java-bridge
and InputFormatProvider
are available for
backwards compatibility.
getScanRuntimeProvider
in interface ScanTableSource
SourceProvider
Copyright © 2014–2024 The Apache Software Foundation. All rights reserved.