Re: Keep the same message in a queue after consuming it.

2013-09-12 Thread Cecilio Alvarez
The example above will not write the same file again and again, when you set noop=true camel set idempotent as well. So this line is now: <--this don't consume the file, so I have always the message. Hope this help. -- View this message in context: http://camel.465427.n5.nabble.com/Keep-the-s

Re: Keep the same message in a queue after consuming it.

2013-09-12 Thread Cecilio Alvarez
Finally I made it using content enricher, <-this override the file, so I always get the last one. <--this don't consume the file, so I have always the message. Finally I use file component, because its easier for users to open a simple xml file to se

Re: Keep the same message in a queue after consuming it.

2013-09-12 Thread Claus Ibsen
Hi Since you use ActiveMQ you can also try with advisory messages and then see if that message has some details about last message enqued so you can use that to see if its the same or new message since last check. http://activemq.apache.org/advisory-message.html On Thu, Sep 12, 2013 at 10:37 AM,

Re: Keep the same message in a queue after consuming it.

2013-09-12 Thread Cecilio Alvarez
Thanks for the tips, I will try it! -- View this message in context: http://camel.465427.n5.nabble.com/Keep-the-same-message-in-a-queue-after-consuming-it-tp5739214p5739235.html Sent from the Camel - Users mailing list archive at Nabble.com.

Re: Keep the same message in a queue after consuming it.

2013-09-12 Thread Claus Ibsen
Hi You can possible use the browse component and do a poll enrich to grab the top message (assuming you get the top message) http://camel.apache.org/content-enricher.html http://camel.apache.org/browse On Thu, Sep 12, 2013 at 10:10 AM, Cecilio Alvarez wrote: > Exactly that, keep procesing the

Re: Keep the same message in a queue after consuming it.

2013-09-12 Thread Cecilio Alvarez
Exactly that, keep procesing the same message again and again until there's a new one. I know sounds strange for camel, but I need to write the same message until there's a new version. I tried with file component with let me override it. But I need to get the message in a producer. Many thanks :)

Re: Keep the same message in a queue after consuming it.

2013-09-12 Thread James Strachan
I don't really grok what you're trying to do or why ;) Wanna explain it? You want to keep processing the same message again and again until there's another one? On 12 September 2013 08:40, Cecilio Alvarez wrote: > Thanks for the fast answer. > I can't send the message back, because that means if

Re: Keep the same message in a queue after consuming it.

2013-09-12 Thread Cecilio Alvarez
Thanks for the fast answer. I can't send the message back, because that means if I send a new message to the queue example.A from file, the sent back message will be consume before. I would like to have something like a LIFO in the queue example.A. And If there is no new message, keep consuming the

Re: Keep the same message in a queue after consuming it.

2013-09-12 Thread James Strachan
The way to do this with messaging is either to rollback (to effectively cancel consuming it) or send the message again On 12 September 2013 07:56, Cecilio Alvarez wrote: > Hi, > is possible to consume a message from a queue in ActiveMQ and keep it in > the > queue for the next consumption of the