JIRA:https://jira.spring.io/browse/AMQP-506 `RabbitTemplate` provides a method `getUnconfirmed` to get aged non-confirmed correlation data. This was not thread-safe. While the `pendingConfirms` objects in `RabbitTemplate` and `PublisherCallbackChannelImpl` are concurrent hash maps, they are maps of maps with the inner maps being `Collections.synchronizedSortedMap`. While iterating over these maps, they must be synchronized. Add a test case to reproduce the exception and verify the problem is resolved. Fix cherry-pick conflicts
Many of the "integration" tests here require a running RabbitMQ server - they will be skipped if the broker is not detected.
If RabbitMQ is not installed on your system, refer to the instructions for your particular OS here: [http://www.rabbitmq.com/install.html]
Start the server. For example, and a *nix-based system where RabbitMQ has been
installed within /opt/rabbitmq, issue the following command:
> sudo /opt/rabbitmq/sbin/rabbitmq-server start