You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@camel.apache.org by pallavi saini <pa...@gmail.com> on 2021/01/06 12:55:17 UTC

How can i make the consumer non-blocking in apache camel route

Hi,
I am trying to introduce reactive approach in my project in the
webservices. For that, have replaced the calling for webservices from
rest-template to web client. The webservice is being called through
camel routing. This is my route.

rest().get("/hello").produces(MediaType.APPLICATION_JSON_VALUE).route()
.to("http:localhost:8082/movies/helloMovie?bridgeEndpoint=true");

I want that this consumer call to be non blocking i.e. caller thread
should get free after hitting the to URI. It should be able to proceed
with other work meanwhile the response is obtained from the to HTTP
call.

Thanks and regards,
Pallavi Saini