如何配置 Spring 集成以使用消息驱动的消费者。使用以下配置,我的消费者正在轮询消息,我无法弄清楚如何使其事件驱动而不是轮询..
<bean id="dataQueue" class="org.apache.activemq.command.ActiveMQQueue">
<constructor-arg name="name" value="${jms.data.queue.name}" />
</bean>
<jms:message-driven-channel-adapter channel="dataInputChannel" destination="dataQueue" />
<int:channel id="dataInputChannel" />
<int:channel id="persistDataChannel" />
<int:channel id="processDataChannel" />
<int:recipient-list-router id="customRouter" input-channel="dataInputChannel" timeout="10000" ignore-send-failures="true" apply-sequence="true">
<int:recipient channel="persistDataChannel"/>
<int:recipient channel="processDataChannel"/>
</int:recipient-list-router>