Jeena
Jeena

Reputation: 309

ActiveMQ one producer multi consumer

I want to write an application using Active MQ as Queue with One producer many consumers. I found http://activemq.apache.org/multiple-consumers-on-a-queue.html that it can be done with creating session but that doesnt provide any example.Can anyone provide me an example of how to do that.

Thanks

Upvotes: 3

Views: 18255

Answers (3)

davidi
davidi

Reputation: 905

I would go for a topic and durable subscribers. A topic will normally deliver the message to the first consumer dequeuing, but if durable subscribers have subscribed to the topic, messages will be delivered to each one of them.

Upvotes: 1

jkysam
jkysam

Reputation: 5779

What you are asking for is the functionality of a Topic, why not use that? Check out: http://activemq.apache.org/how-does-a-queue-compare-to-a-topic.html

Upvotes: 2

Related Questions