You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@camel.apache.org by Litom <Li...@liveperson.com> on 2014/11/26 23:25:59 UTC

Sending a Request to camel rout from rx java observable

 How can I call a camel rout from rx java observable, and get a reply?
I wish the call to be non blocking, when the component   supports
asynchronous processing.
I tried to use producerTemplate.asyncRequest and noticed that It's thread is
blocked,  waiting on latch for a response.




--
View this message in context: http://camel.465427.n5.nabble.com/Sending-a-Request-to-camel-rout-from-rx-java-observable-tp5759677.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Re: Sending a Request to camel rout from rx java observable

Posted by Litom <Li...@liveperson.com>.
Thanks a lot for your reply. What if I want to call a direct endpoint, which
eventually goes to an async producer? Should I call the direct producer
directly?
Is there an example for that, in the documentations/book?



--
View this message in context: http://camel.465427.n5.nabble.com/Sending-a-Request-to-camel-rout-from-rx-java-observable-tp5759677p5759741.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Re: Sending a Request to camel rout from rx java observable

Posted by Willem Jiang <wi...@gmail.com>.
That’s part of UnitOfWorkProducer job which means we get the response there.
As not all the camel endpoints implement the async invocation API, we cannot use the async invocation by default.

If the endpoint support the async invocation, you can call the producer async API yourself without using the one from the ProucerTemplate.

--  
Willem Jiang

Red Hat, Inc.
Web: http://www.redhat.com
Blog: http://willemjiang.blogspot.com (English)
http://jnn.iteye.com (Chinese)
Twitter: willemjiang  
Weibo: 姜宁willem



On November 27, 2014 at 6:27:58 AM, Litom (litoms@liveperson.com) wrote:
> How can I call a camel rout from rx java observable, and get a reply?
> I wish the call to be non blocking, when the component supports
> asynchronous processing.
> I tried to use producerTemplate.asyncRequest and noticed that It's thread is
> blocked, waiting on latch for a response.
>  
>  
>  
>  
> --
> View this message in context: http://camel.465427.n5.nabble.com/Sending-a-Request-to-camel-rout-from-rx-java-observable-tp5759677.html  
> Sent from the Camel - Users mailing list archive at Nabble.com.
>