camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Morgan Hautman <>
Subject Re: REST InOut with JMS InOnly
Date Tue, 03 Feb 2015 13:20:00 GMT
Yes I understand we can encounter a timeout when we don't respond to 
http/rest because it's synchronous.

But I think what James means is :

1st route:

2nd route
from(activemq: bar).to(processing)

The first route sends a message to the second route through activemq and 
waits for the second route to process the message and the second route 
respond to the first route who will answer to the client what "route2" 
responded. (timeout or not)

Hope It's comprehensive.

PS: I'm not in James team, I just try to help and understand a problem I 
had myself some months ago but didn't look further.

On 3/02/2015 13:54, Claus Ibsen wrote:
> On Tue, Feb 3, 2015 at 1:27 PM, Morgan Hautman <> wrote:
>> Claus,
>> Is their any way a queue (using activemq) could respond , like a
>> request-reply mechanism?
> Not sure I follow. Camel can do InOnly and InOut over JMS. So yeah
> both is possible.
> Just mind that a client like HTTP / REST is synchronous in that sense
> the client awaits a response, so whether that is just a OK or to
> respond with some new data, then that needs to happen, and occurs when
> the exchange is done being routed, and the control is back at the
> consumer.
>> On 3/02/2015 13:14, Claus Ibsen wrote:
>>> Hi
>>> You can send the message to the JMS as InOnly or use WireTap
>>> On Tue, Feb 3, 2015 at 12:27 PM, James Green <>
>>> wrote:
>>>> I have two routes:
>>>> 1. A rest dsl accepting data from HTTP clients and sending it to the
>>>> route
>>>> below before replying to the client
>>>> 2. A "backend" route that receives an Exchange and sends it to a JMS
>>>> queue
>>>> By default, although the JMS queue gets the message, a stack trace occurs
>>>> because the queue did not respond. So I set the backend route to be
>>>> InOnly
>>>> and now no stack trace occurs.
>>>> However, the remaining part of my rest dsl route does not execute.
>>>> So how do I accept some REST request, fire off an asynchronous JMS
>>>> message,
>>>> and reply to the HTTP client?
>>>> Thanks,
>>>> James

View raw message