Interface EncodingFormat<I>
-
- Type Parameters:
I- runtime interface needed by the table sink
- All Superinterfaces:
Format
@PublicEvolving public interface EncodingFormat<I> extends Format
AFormatfor aDynamicTableSinkfor writing rows.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description default voidapplyWritableMetadata(List<String> metadataKeys)Provides a list of metadata keys that the consumed row will contain as appended metadata columns.IcreateRuntimeEncoder(DynamicTableSink.Context context, DataType physicalDataType)Creates runtime encoder implementation that is configured to consume data of the given data type.default Map<String,DataType>listWritableMetadata()Returns the map of metadata keys and their corresponding data types that can be consumed by this format for writing.-
Methods inherited from interface org.apache.flink.table.connector.format.Format
getChangelogMode
-
-
-
-
Method Detail
-
createRuntimeEncoder
I createRuntimeEncoder(DynamicTableSink.Context context, DataType physicalDataType)
Creates runtime encoder implementation that is configured to consume data of the given data type.
-
listWritableMetadata
default Map<String,DataType> listWritableMetadata()
Returns the map of metadata keys and their corresponding data types that can be consumed by this format for writing. By default, this method returns an empty map.Metadata columns add additional columns to the table's schema. An encoding format is responsible to accept requested metadata columns at the end of consumed rows and persist them.
See
SupportsWritingMetadatafor more information.Note: This method is only used if the outer
DynamicTableSinkimplementsSupportsWritingMetadataand calls this method inSupportsWritingMetadata.listWritableMetadata().
-
applyWritableMetadata
default void applyWritableMetadata(List<String> metadataKeys)
Provides a list of metadata keys that the consumed row will contain as appended metadata columns. By default, this method throws an exception if metadata keys are defined.See
SupportsWritingMetadatafor more information.Note: This method is only used if the outer
DynamicTableSinkimplementsSupportsWritingMetadataand calls this method inSupportsWritingMetadata.applyWritableMetadata(List, DataType).
-
-