}
private void createConnectionFailure(Connection connection) throws Exception {
ActiveMQConnection c = ((PooledConnection)connection).getConnection();
MockTransport t = (MockTransport)c.getTransportChannel().narrow(MockTransport.class);
t.onException(new IOException("forcing exception for " + getName() + " to force pool eviction"));
LOG.info("arranged for failure, chucked exception");
}
private void sendMessage(Connection connection) throws JMSException {
Session session = connection.createSession(false, Session.AUTO_ACKNOWLEDGE);