Buggy code:
public abstract class AbstractMessageBrokerConfiguration implements ApplicationContextAware { private static final boolean jackson2Present = ClassUtils . isPresent ( "com.fasterxml.jackson.databind.ObjectMapper" , AbstractMessageBrokerConfiguration . class . getClassLoader ( ) ) ; private static final String MVC_VALIDATOR_NAME = "mvcValidator" ; private ChannelRegistration clientInboundChannelRegistration ; private ChannelRegistration clientOutboundChannelRegistration ; private MessageBrokerRegistry brokerRegistry ; private ApplicationContext applicationContext ; protected AbstractMessageBrokerConfiguration ( ) { } @ Bean public AbstractSubscribableChannel clientInboundChannel ( ) { } @ Bean public ThreadPoolTaskExecutor clientInboundChannelExecutor ( ) { } protected final ChannelRegistration getClientInboundChannelRegistration ( ) { } protected void configureClientInboundChannel ( ChannelRegistration registration ) { } @ Bean public AbstractSubscribableChannel clientOutboundChannel ( ) { } @ Bean public ThreadPoolTaskExecutor clientOutboundChannelExecutor ( ) { } protected final ChannelRegistration getClientOutboundChannelRegistration ( ) { } protected void configureClientOutboundChannel ( ChannelRegistration registration ) { } @ Bean public AbstractSubscribableChannel brokerChannel ( ) { } @ Bean public ThreadPoolTaskExecutor brokerChannelExecutor ( ) { } protected final MessageBrokerRegistry getBrokerRegistry ( ) { } protected void configureMessageBroker ( MessageBrokerRegistry registry ) { } @ Bean public SimpAnnotationMethodMessageHandler simpAnnotationMethodMessageHandler ( ) { } @ Bean public AbstractBrokerMessageHandler simpleBrokerMessageHandler ( ) { } @ Bean public AbstractBrokerMessageHandler stompBrokerRelayMessageHandler ( ) { } @ Bean public UserDestinationMessageHandler userDestinationMessageHandler ( ) { <START_BUG> UserDestinationMessageHandler handler = new UserDestinationMessageHandler ( clientInboundChannel ( ) , clientOutboundChannel ( ) , brokerChannel ( ) , userDestinationResolver ( ) ) ; <END_BUG> return handler ; } @ Bean public SimpMessagingTemplate brokerMessagingTemplate ( ) { } @ Bean public CompositeMessageConverter brokerMessageConverter ( ) { } protected boolean configureMessageConverters ( List < MessageConverter > messageConverters ) { } protected ContentTypeResolver getContentTypeResolver ( ) { } @ Bean public UserDestinationResolver userDestinationResolver ( ) { } @ Bean public UserSessionRegistry userSessionRegistry ( ) { } @ Override public void setApplicationContext ( ApplicationContext applicationContext ) throws BeansException { } public ApplicationContext getApplicationContext ( ) { } protected Validator simpValidator ( ) { } public Validator getValidator ( ) { } private static final AbstractBrokerMessageHandler noopBroker = new AbstractBrokerMessageHandler ( null ) { @ Override protected void startInternal ( ) { } @ Override protected void stopInternal ( ) { } @ Override protected void handleMessageInternal ( Message < ? > message ) { } } ; }

Fix:
UserDestinationMessageHandler handler = new UserDestinationMessageHandler ( clientInboundChannel ( ) , brokerChannel ( ) , userDestinationResolver ( ) ) ;