Reputation: 613
how can I change the default behaviour which makes my queues durable? I want them to be non-durable. The queues are created in the runtime as a backend for websockets. There is a default exchange defined which has durable feature set to TRUE. I played a bit with exchanges but could not make it work as I expect.
Upvotes: 0
Views: 2649
Reputation: 117
When you declare a queue using the Channel class, you can see those parameters:
Queue.DeclareOk queueDeclare(String queue, boolean durable, boolean exclusive, boolean autoDelete,
Map<String, Object> arguments) throws IOException;
I am using:
'amqp-client:3.5.4'
Upvotes: 2
Reputation: 72888
typically, you just set "durable=false" in whatever library is declaring the queue.
for example,
python: channel.queue_declare(queue='hello', durable=True)
java:
boolean durable = true; channel.queueDeclare("hello", durable, false, false, null);
you can find other language examples in the worker queue example on RabbitMQ.com
you should consult the documentation for the library you are using, though
Upvotes: 1