ruby-amqp / bunny

Bunny is a popular, easy to use, mature Ruby client for RabbitMQ
Other
1.39k stars 304 forks source link

Cannot subscribe to existing queue with no configure permission #613

Closed JOravas closed 3 years ago

JOravas commented 3 years ago

RabbitMQ version 3.8.11 Bunny 2.17.0

Preconditions:

I cannot subscribe to this existing named queue from Bunny as there is ACCESS_REFUSED exception.

In RabbitMQ log:

operation queue.declare caused a channel exception access_refused.

michaelklishin commented 3 years ago

If your code involves declaring a queue — and Bunny::Channel#queue does just that — the user must have a configure permission on the target queue.

You can do a passive declare (pass passive: true to Bunny::Channel#queue) or use Bunny::Channel#basic_consume directly without all the DSL-y sugar.

michaelklishin commented 3 years ago

I will convert this issue to a GitHub discussion. Currently GitHub will automatically close and lock the issue even though your question will be transferred and responded to elsewhere. This is to let you know that we do not intend to ignore this but this is how the current GitHub conversion mechanism makes it seem for the users :(