my dog learned polymorphism
The moose likes EJB and other Java EE Technologies and the fly likes activemq queue problem Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of REST with Spring (video course) this week in the Spring forum!
JavaRanch » Java Forums » Java » EJB and other Java EE Technologies
Bookmark "activemq queue problem" Watch "activemq queue problem" New topic

activemq queue problem

Ishant Agarwal

Joined: Sep 09, 2011
Posts: 22
Hello Everyone,

I am using activemq where my publisher class used queue for sending persistent messages and consumer class used to dequeued mesages from the selected queue, below given code which I am suing for the same:-

now when i first run my publisher class it sends message and then when i run my consumer class it tooks the message from queue but when i stop my consumer class and then restart it, it again took the same message which it consumes before.kindly correct me where i am doing wrong code and enable me to consumer only those messages which did not consumer ever before.

With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
subject: activemq queue problem
It's not a secret anymore!