<control-bus input-channel ="inboundChannel/>
<channel id ="inboundChannel"/>
<message-driven-channel-adapter id="inAQueue" channel="inboundChannel"
auto-startup="false" container="DefaultContainer"/>
<service-activator input-channel="inboundChannel" ref="Something"
method="abc"/>
inboundChannel.send(MessageBuilder.withPayload(“ @ inAQueue.stop()”)。build();
inboundChannel.send(MessageBuilder.withPayload(“ @ inAQueue.start()”)。build());
But my service activator class receive this message and throws class cast exception that string can not be cast to jmstextMessage.
我不确定我是否以正确的方式尝试它。
答案 0 :(得分:0)
您在inboundChannel
上有2个订阅者-消息驱动适配器和控制总线。消息将以循环方式分发。
控制总线应订阅自己的通道,控制消息将发送到该通道。