-
-
Save pcan/0f79bd7a8670ce5a28add1e26b6ed5e6 to your computer and use it in GitHub Desktop.
Create a Spring Integration Channel programatically and register that as a Spring bean
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
private SubscribableChannel createInputChannel(String inputChannelName) { | |
PublishSubscribeChannel channel = new PublishSubscribeChannel(); | |
channel.setBeanName(inputChannelName); | |
channel.setBeanFactory(applicationContext); | |
//channel.setApplySequence(true); | |
((ConfigurableApplicationContext)applicationContext).getBeanFactory().registerSingleton(inputChannelName, channel); | |
return channel; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment