Interface KeyedDeserializationSchema<T>
- Type Parameters:
T- The type created by the keyed deserialization schema.
- All Superinterfaces:
KafkaDeserializationSchema<T>,org.apache.flink.api.java.typeutils.ResultTypeQueryable<T>,Serializable
@Deprecated
@PublicEvolving
public interface KeyedDeserializationSchema<T>
extends KafkaDeserializationSchema<T>
Deprecated.
The deserialization schema describes how to turn the byte key / value messages delivered by
certain data sources (for example Apache Kafka) into data types (Java/Scala objects) that are
processed by Flink.
-
Method Summary
Modifier and TypeMethodDescriptiondeserialize(byte[] messageKey, byte[] message, String topic, int partition, long offset) Deprecated.Deserializes the byte message.default Tdeserialize(org.apache.kafka.clients.consumer.ConsumerRecord<byte[], byte[]> record) Deprecated.Deserializes the Kafka record.Methods inherited from interface org.apache.flink.streaming.connectors.kafka.KafkaDeserializationSchema
deserialize, isEndOfStream, openMethods inherited from interface org.apache.flink.api.java.typeutils.ResultTypeQueryable
getProducedType
-
Method Details
-
deserialize
T deserialize(byte[] messageKey, byte[] message, String topic, int partition, long offset) throws IOException Deprecated.Deserializes the byte message.- Parameters:
messageKey- the key as a byte array (null if no key has been set).message- The message, as a byte array (null if the message was empty or deleted).partition- The partition the message has originated from.offset- the offset of the message in the original source (for example the Kafka offset).- Returns:
- The deserialized message as an object (null if the message cannot be deserialized).
- Throws:
IOException
-
deserialize
default T deserialize(org.apache.kafka.clients.consumer.ConsumerRecord<byte[], byte[]> record) throws IOExceptionDeprecated.Description copied from interface:KafkaDeserializationSchemaDeserializes the Kafka record.- Specified by:
deserializein interfaceKafkaDeserializationSchema<T>- Parameters:
record- Kafka record to be deserialized.- Returns:
- The deserialized message as an object (null if the message cannot be deserialized).
- Throws:
IOException
-
KafkaDeserializationSchema.