AMQP: declare exchange and queue to be non-durable and auto-deleted to avoid pollution of the broker

This commit is contained in:
Sonja Happ 2021-09-30 16:02:01 +02:00
parent 3a0da86d92
commit e65763e8ab

View file

@ -71,8 +71,8 @@ func ConnectAMQP(uri string, cb callback) error {
// declare exchange // declare exchange
err = client.sendCh.ExchangeDeclare(VILLAS_EXCHANGE, err = client.sendCh.ExchangeDeclare(VILLAS_EXCHANGE,
"headers", "headers",
true,
false, false,
true,
false, false,
false, false,
nil) nil)
@ -82,8 +82,8 @@ func ConnectAMQP(uri string, cb callback) error {
// add a queue for the ICs // add a queue for the ICs
ICQueue, err := client.sendCh.QueueDeclare("infrastructure_components", ICQueue, err := client.sendCh.QueueDeclare("infrastructure_components",
true,
false, false,
true,
false, false,
false, false,
nil) nil)