[rabbitmq-discuss] Regd: Publish Many Scenarios

Emile Joubert emile at rabbitmq.com
Tue Feb 7 09:50:35 GMT 2012


On 07/02/12 08:32, preeti sp wrote:
> Is there any way we could handle the scenario of Multiple Producers and
> Multiple Consumers bound to the same Queue using RabbitMQ ? Description
> below!
> (1) Bind Multiple consumers to one Queue based on some binding keys

Yes, it is possible for multiple consumers to subscribe to the same
queue, but each message will only be delivered to one consumer. If you
want each consumer to receive each message then you will need to declare
a queue for each consumer and bind the queues to an exchange. Compare
the second and third tutorials for an illustration:

> (2) Multiple publishers publish some messages to the above Queue

Yes, but bear in mind that publishers publish to an exchange, not to a
queue directly.

> (3) And, Ensure each of the consumers get a copy of each message

No, see the answer to (1) above.


More information about the rabbitmq-discuss mailing list