@Internal public class KinesisDynamicSink extends Object implements DynamicTableSink, SupportsPartitioning
DynamicTableSink
.DynamicTableSink.Context, DynamicTableSink.DataStructureConverter, DynamicTableSink.SinkRuntimeProvider
Constructor and Description |
---|
KinesisDynamicSink(DataType consumedDataType,
String stream,
Properties producerProperties,
EncodingFormat<SerializationSchema<RowData>> encodingFormat,
KinesisPartitioner<RowData> partitioner) |
Modifier and Type | Method and Description |
---|---|
void |
applyStaticPartition(Map<String,String> partition)
Provides the static part of a partition.
|
String |
asSummaryString()
Returns a string that summarizes this sink for printing to a console or log.
|
DynamicTableSink |
copy()
Creates a copy of this instance during planning.
|
boolean |
equals(Object o) |
ChangelogMode |
getChangelogMode(ChangelogMode requestedMode)
Returns the set of changes that the sink accepts during runtime.
|
DynamicTableSink.SinkRuntimeProvider |
getSinkRuntimeProvider(DynamicTableSink.Context context)
Returns a provider of runtime implementation for writing the data.
|
int |
hashCode() |
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
requiresPartitionGrouping
public KinesisDynamicSink(DataType consumedDataType, String stream, Properties producerProperties, EncodingFormat<SerializationSchema<RowData>> encodingFormat, KinesisPartitioner<RowData> partitioner)
public ChangelogMode getChangelogMode(ChangelogMode requestedMode)
DynamicTableSink
The planner can make suggestions but the sink has the final decision what it requires. If
the planner does not support this mode, it will throw an error. For example, the sink can
return that it only supports ChangelogMode.insertOnly()
.
getChangelogMode
in interface DynamicTableSink
requestedMode
- expected set of changes by the current planpublic DynamicTableSink.SinkRuntimeProvider getSinkRuntimeProvider(DynamicTableSink.Context context)
DynamicTableSink
There might exist different interfaces for runtime implementation which is why DynamicTableSink.SinkRuntimeProvider
serves as the base interface. Concrete DynamicTableSink.SinkRuntimeProvider
interfaces might be located in other Flink modules.
Independent of the provider interface, the table runtime expects that a sink
implementation accepts internal data structures (see RowData
for more information).
The given DynamicTableSink.Context
offers utilities by the planner for creating runtime
implementation with minimal dependencies to internal data structures.
See org.apache.flink.table.connector.sink.SinkFunctionProvider
in flink-table-api-java-bridge
.
getSinkRuntimeProvider
in interface DynamicTableSink
ParallelismProvider
public DynamicTableSink copy()
DynamicTableSink
copy
in interface DynamicTableSink
public String asSummaryString()
DynamicTableSink
asSummaryString
in interface DynamicTableSink
public void applyStaticPartition(Map<String,String> partition)
SupportsPartitioning
A single partition maps each partition key to a partition value. Depending on the user-defined statement, the partition might not include all partition keys.
See the documentation of SupportsPartitioning
for more information.
applyStaticPartition
in interface SupportsPartitioning
partition
- user-defined (possibly partial) static partitionCopyright © 2014–2021 The Apache Software Foundation. All rights reserved.