升级Spring Boot与Spring Cloud后Kafka消费者无法接收消息
Spring Boot 3.1.0 与 Spring Cloud 2022.0.3 升级后 Kafka 消费者异常问题
问题描述
- 升级至 Spring Boot 3.1.0、Spring Cloud 2022.0.3 版本后,Kafka 消费者无法正常工作,但生产者运行正常
- 低版本环境下该功能表现正常
服务1(生产者)配置
cloud: stream: bindings: someBinding-out-0: destination: some_binding content-type: application/x-protobuf
- 通过 Stream Bridge 发送消息,无异常
服务2(消费者)配置
function: definition: someBinding bindings: someBinding-in-0: consumer: max-attempts: 1 partitioned: true concurrency: 10 destination: some_binding group: someBindingProcessingGroup content-type: application/x-protobuf
消费者代码实现
public Consumer<Message<SomeClass>> someBinding() { return someBinding -> {}; }
内容的提问来源于stack exchange,提问作者morj
相关产品推荐
相关产品推荐

