bschmitt / laravel-amqp

AMQP wrapper for Laravel and Lumen to publish and consume messages
MIT License
268 stars 86 forks source link

Disable exchange and queue declare in setup method #36

Open r-patrik opened 6 years ago

r-patrik commented 6 years ago

Hello!

It would be great if exchange and queue declaration could be disabled in setup method, cause if you declared a queue for example with dead letter exchange, you have to define this property in consume method, otherwise rabbit will throw an error because your package is try to define a queue with the same name and another properties.

Another problem is you dont merge the queue_properties key with defaults, so i have to add the defaults manually to the properties to every time in my code.

Anyway i think it's not okay that the code always try to declare queues and exchanges cause it's unnecessary communication every time with the server. It would be great to pass a property to declare these things in setup or not.

Thanks!

lty628 commented 1 year ago

I also have this problem and look forward to solving it