@@ -66,7 +66,6 @@ import org.springframework.context.annotation.Bean;
|
||||
import org.springframework.context.annotation.Configuration;
|
||||
import org.springframework.context.annotation.Import;
|
||||
import org.springframework.context.annotation.Role;
|
||||
import org.springframework.context.annotation.Scope;
|
||||
import org.springframework.core.annotation.AnnotationUtils;
|
||||
import org.springframework.core.env.Environment;
|
||||
import org.springframework.core.env.StandardEnvironment;
|
||||
@@ -136,14 +135,11 @@ public class BinderFactoryAutoConfiguration {
|
||||
|
||||
|
||||
@Bean(IntegrationContextUtils.MESSAGE_HANDLER_FACTORY_BEAN_NAME)
|
||||
@Scope("prototype")
|
||||
public static MessageHandlerMethodFactory messageHandlerMethodFactory(
|
||||
@Qualifier(IntegrationContextUtils.ARGUMENT_RESOLVER_MESSAGE_CONVERTER_BEAN_NAME) CompositeMessageConverter compositeMessageConverter,
|
||||
@Nullable Validator validator, ConfigurableListableBeanFactory clbf) {
|
||||
|
||||
DefaultMessageHandlerMethodFactory messageHandlerMethodFactory = new DefaultMessageHandlerMethodFactory();
|
||||
// CompositeMessageConverter messageConverter =
|
||||
// compositeMessageConverterFactory.getMessageConverterForAllRegistered();
|
||||
messageHandlerMethodFactory.setMessageConverter(compositeMessageConverter);
|
||||
|
||||
/*
|
||||
|
||||
@@ -39,14 +39,6 @@ import org.springframework.messaging.converter.MessageConverter;
|
||||
@Role(BeanDefinition.ROLE_INFRASTRUCTURE)
|
||||
class ContentTypeConfiguration {
|
||||
|
||||
// @Bean
|
||||
// public CompositeMessageConverterFactory compositeMessageConverterFactory(
|
||||
// ObjectProvider<ObjectMapper> objectMapperObjectProvider, List<MessageConverter> customMessageConverters) {
|
||||
//
|
||||
// return new CompositeMessageConverterFactory(customMessageConverters,
|
||||
// objectMapperObjectProvider.getIfAvailable(ObjectMapper::new));
|
||||
// }
|
||||
|
||||
@Bean(name = IntegrationContextUtils.ARGUMENT_RESOLVER_MESSAGE_CONVERTER_BEAN_NAME)
|
||||
public ConfigurableCompositeMessageConverter configurableCompositeMessageConverter(
|
||||
ObjectProvider<ObjectMapper> objectMapperObjectProvider,
|
||||
@@ -59,8 +51,6 @@ class ContentTypeConfiguration {
|
||||
messageConverters.addAll(customMessageConverters);
|
||||
|
||||
return new ConfigurableCompositeMessageConverter(messageConverters);
|
||||
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user