camel-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Claus Ibsen <claus.ib...@gmail.com>
Subject [DISCUSS] - JMSReplyTo to yourself
Date Thu, 20 Jan 2011 06:38:57 GMT
Hi

Suppose you have a Camel route

from("activemq:queue:foo")
   .process(xxx)

And a client sends a message to the foo queue with a JMSReplyTo header
set with the queue:foo destination.
The client has essentially told to send a reply back to the same queue
as the message was consumed.

Currently Camel will happily comply and send a reply message to the
foo queue. Now what could happen is the message will keep doing this.

Is there any use-cases in the real life where you want to send a reply
message back to the same message queue?
If not we can implement logic to detect this and avoid doing that.
Camel can log a WARN when it has detect this so
end users can notice in the logs if they have such a case.

We can introduce an option so people can turn this odd behavior on and
allow to send back replies to same queue.


The current remedy is to enable this option as follows:

from("activemq:queue:foo?disableReplyTo=true")
   .process(xxx)

But that's general so if there was a JMSReplyTo header with the
queue:bar then it would be ignored as well.
However sending to a bar queue may be a valid use-case.




-- 
Claus Ibsen
-----------------
FuseSource
Email: cibsen@fusesource.com
Web: http://fusesource.com
Twitter: davsclaus
Blog: http://davsclaus.blogspot.com/
Author of Camel in Action: http://www.manning.com/ibsen/

Mime
View raw message