As part of my routes, I need a processor to calculate and set a delay in the
distribution. The message should be released to the Activemq topic/queue,
but only send to subscribers when the delay has expired.

AMQ_SCHEDULED_DELAY seems ideal for this. But I cant get it to work.

In my processor bean I have

  exchange.getIn().setHeader("AMQ_SCHEDULED_DELAY", delay);

The exchange I thereafter route to an activemq endpoint.

The problem is that the subscriber receives all messages immediately, no
matter the delay set. It looks as if the AMQ_SCHEDULED_DELAY header flag is
not taken into account. 

What am I doing wrong?

--
View this message in context: 
http://camel.465427.n5.nabble.com/Howto-use-delay-message-brokerage-in-a-Camel-Route-using-AMQ-SCHEDULED-DELAY-tp4282763p4282763.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Reply via email to