1) The server sends a message to the client.
2) The incoming channel adapter is configured to wait for the user confirmation mode "MANUAL" from the user
3) The "TaskBundlereceiver" bean implements the "ChannelAwareMessageListener", and in the implementation method I carry out a message confirmation.
I do not see the "TaskBundlereceiver" running. Did I miss something?
Below are the configuration details of the steps that I have explained.
Rate your entries.
@Override public void onMessage(org.springframework.amqp.core.Message message, Channel channel) throws Exception { logger.debug("In onMessage method of the channel aware listener. message =["+message.getBody().toString()+"]"); channel.basicAck(message.getMessageProperties().getDeliveryTag(), true); }
XML configuration:
<int:channel id="fromKServerChannel"/> <int-amqp:inbound-channel-adapter id="taskBundleReceiverAdapter" channel="fromKServerChannel" error-channel="taskBundleErrorChannel" acknowledge-mode="MANUAL" expose-listener-channel="true" queue-names="kanga_task_queue" connection-factory="connectionFactory" concurrent-consumers="20"/> <int:chain input-channel="fromKServerChannel" output-channel="nullChannel"> <int:service-activator ref="taskBundleReceiver" method="onMessage"/> <int:service-activator ref="taskBundleExecutor" method="executeBundle"/> </int:chain>
source share