From 745d1738983d840e42f51fe1e5e696686b104760 Mon Sep 17 00:00:00 2001 From: zkzlx Date: Thu, 26 Aug 2021 15:20:04 +0800 Subject: [PATCH] message converter --- .../ExtendedBindingHandlerMappingsProviderConfiguration.java | 3 +++ .../binder/rocketmq/convert/RocketMQMessageConverter.java | 4 ++-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/spring-cloud-alibaba-starters/spring-cloud-starter-stream-rocketmq/src/main/java/com/alibaba/cloud/stream/binder/rocketmq/autoconfigurate/ExtendedBindingHandlerMappingsProviderConfiguration.java b/spring-cloud-alibaba-starters/spring-cloud-starter-stream-rocketmq/src/main/java/com/alibaba/cloud/stream/binder/rocketmq/autoconfigurate/ExtendedBindingHandlerMappingsProviderConfiguration.java index ce48fccb0..df5d47b6b 100644 --- a/spring-cloud-alibaba-starters/spring-cloud-starter-stream-rocketmq/src/main/java/com/alibaba/cloud/stream/binder/rocketmq/autoconfigurate/ExtendedBindingHandlerMappingsProviderConfiguration.java +++ b/spring-cloud-alibaba-starters/spring-cloud-starter-stream-rocketmq/src/main/java/com/alibaba/cloud/stream/binder/rocketmq/autoconfigurate/ExtendedBindingHandlerMappingsProviderConfiguration.java @@ -53,6 +53,9 @@ public class ExtendedBindingHandlerMappingsProviderConfiguration { } + /** + * if you want to customize a bean, please use this BeanName {@code RocketMQMessageConverter.DEFAULT_NAME}. + */ @Bean(RocketMQMessageConverter.DEFAULT_NAME) @ConditionalOnMissingBean(name = { RocketMQMessageConverter.DEFAULT_NAME }) public CompositeMessageConverter rocketMQMessageConverter() { diff --git a/spring-cloud-alibaba-starters/spring-cloud-starter-stream-rocketmq/src/main/java/com/alibaba/cloud/stream/binder/rocketmq/convert/RocketMQMessageConverter.java b/spring-cloud-alibaba-starters/spring-cloud-starter-stream-rocketmq/src/main/java/com/alibaba/cloud/stream/binder/rocketmq/convert/RocketMQMessageConverter.java index 98bd03263..f69290997 100644 --- a/spring-cloud-alibaba-starters/spring-cloud-starter-stream-rocketmq/src/main/java/com/alibaba/cloud/stream/binder/rocketmq/convert/RocketMQMessageConverter.java +++ b/spring-cloud-alibaba-starters/spring-cloud-starter-stream-rocketmq/src/main/java/com/alibaba/cloud/stream/binder/rocketmq/convert/RocketMQMessageConverter.java @@ -34,9 +34,9 @@ import org.springframework.util.ClassUtils; public class RocketMQMessageConverter { /** - * rocketMQMessageConverter. + * if you want to customize a bean, please use the BeanName. */ - public static final String DEFAULT_NAME = "rocketMQMessageConverter"; + public static final String DEFAULT_NAME = "com.alibaba.cloud.stream.binder.rocketmq.convert.RocketMQMessageConverter"; private static final boolean JACKSON_PRESENT;