spring-projects/spring-amqp — pull request #172 by garyrussell (2014-03-08 16:26:54+00:00)
Title: AMQP-383 Fix Auto-Delete Queue Redeclaration

JIRA: https://jira.spring.io/browse/AMQP-383

When an auto-delete queue is removed by the broker, its
bindings are removed too. If the binding is the last one
for an auto-delete exchange, the exchange is deleted too.
If that exchange is bound to another exchange, its binding
is removed, etc, etc.

AMQP-373 only redeclares the queue and any upstream infrastructure
was not redeclared.

Added an integration test with an auto-delete exchange and queue.

Now, during container start, if an auto-delete queue is detected to
be missing, the entire `RabbitAdmin.initialize()` is invoked to
redeclare all context elements.