【发布时间】:2018-12-04 00:25:41
【问题描述】:
我正在使用一个 kafka 生产者和一个 Spring kafka 消费者。我正在使用 Json 序列化器和反序列化器。每当我尝试从主题中读取消费者中的消息时,我都会收到以下错误:
org.apache.kafka.common.errors.SerializationException: Error deserializing key/value for partition fan_topic-0 at offset 154. If needed, please seek past the record to continue consumption.
Caused by: java.lang.IllegalStateException: No type information in headers and no default type provided
我没有在生产者和消费者中配置任何有关标头的内容。我在这里错过了什么?
【问题讨论】:
标签: apache-kafka kafka-consumer-api kafka-producer-api spring-kafka