Class PubSubMessageDeserializer


  • public class PubSubMessageDeserializer
    extends java.lang.Object
    The class for deserializing messages from the pubsub specific message format to PubSubMessage
    • Method Detail

      • deserialize

        public PubSubMessage<KafkaKey,​KafkaMessageEnvelope,​java.lang.Long> deserialize​(PubSubTopicPartition topicPartition,
                                                                                                   byte[] keyBytes,
                                                                                                   byte[] valueBytes,
                                                                                                   PubSubMessageHeaders headers,
                                                                                                   java.lang.Long position,
                                                                                                   java.lang.Long timestamp)
        Deserialize a message from the pubsub specific message format to PubSubMessage.
        Parameters:
        topicPartition - the topic partition from which the message was read
        keyBytes - the key bytes of the message
        valueBytes - the value bytes of the message
        headers - the headers of the message
        position - the position of the message in the topic partition
        timestamp - the timestamp of the message
        Returns:
        the deserialized PubSubMessage
      • close

        public void close()