assertNotNull("Reply is expected", reply);
assertEquals(new String(message.getBody()), new String(reply.getBody()));
// Message was consumed so nothing left on queue
reply = template.receive();
assertEquals(null, reply);
cachingConnectionFactory.destroy();
}
@Test
public void testAtomicSendAndReceiveExternalExecutor() throws Exception {
final CachingConnectionFactory connectionFactory = new CachingConnectionFactory();