T - the type of input record being serializedpublic interface RecordSerializationSchema<T> extends Serializable
T to StarRocksRowData.| Modifier and Type | Method and Description |
|---|---|
void |
close()
Close the serializer
|
void |
open(org.apache.flink.api.common.serialization.SerializationSchema.InitializationContext context,
StarRocksSinkContext sinkContext)
Initialization method for the schema.
|
StarRocksRowData |
serialize(T record)
Serializes the given record and returns it as a
StarRocksRowData. |
void open(org.apache.flink.api.common.serialization.SerializationSchema.InitializationContext context,
StarRocksSinkContext sinkContext)
serialize(Object) and thus suitable for one-time setup work.
The provided SerializationSchema.InitializationContext can be used to access
additional features such as e.g. registering user metrics.
context - Contextual information that can be used during initialization.sinkContext - runtime information i.e. partitions, subtaskId@Nullable StarRocksRowData serialize(T record)
StarRocksRowData.record - element to be serializedStarRocksRowData or null if the given record cannot be serializedvoid close()
Copyright © 2024. All rights reserved.