Oren Yosifon
Oren Yosifon

Reputation: 927

RabbitMQ: similar queues in different exchanges

Can I have two queues with the same name and same routingKey yet each bound to another exchange?

Upvotes: 5

Views: 3112

Answers (2)

Simon MacMullen
Simon MacMullen

Reputation: 834

You can't have two queues with the same name at all, (well you can if they're in different virtual hosts but I don't think that's what you're talking about).

However, you can bind one queue to many exchanges, or to one exchange with many routing keys. If you're aiming to have a single consumer pick up messages from several exchanges, that's what you want to do.

Upvotes: 5

old_sound
old_sound

Reputation: 2313

You can't do that, unless those queues are in different vhosts.

Upvotes: 5

Related Questions