I can use only one thread for sending messages becuase I can have only single TCP connection to external server. I want to be able to send multiple requests one after the other without waiting for a response. responses need to be processed asynchronously. any solutions for this scenario?. I am unable to use camel 2.2 as I have package scanning problem in weblogic. here is one possible solution but I am not sure about the life cycle of the mina endpoint, is it possible to loose messages with this solution.
from("file:///test/test/response") .convertBodyTo(String.class).threads(1) .to("mina:tcp://localhost:6202?sync=false&textline=true&filters=#listFilters"); from("vm:response") .to("log:+++ reply++++"); public class MessageFilter extends IoFilterAdapter { @Produce(uri = "vm:response") ProducerTemplate producer; @Override public void messageReceived(NextFilter nextFilter, IoSession session, Object message) throws Exception { if (message instanceof String) { producer.sendBody(message); } nextFilter.messageReceived(session, message); } } -- View this message in context: http://old.nabble.com/single-tcp-connection-with-async-requests-and-async-responses-tp27850137p27850137.html Sent from the Camel - Users mailing list archive at Nabble.com.