if (BROKER.startsWith("vm://"))
{
ApplicationRegistry.getInstance(1);
TransportConnection.createVMBroker(1);
}
InitialContextFactory factory = new PropertiesFileInitialContextFactory();
Hashtable<String, String> env = new Hashtable<String, String>();
env.put("connectionfactory.connection", "amqp://guest:guest@TTL_TEST_ID/" + VHOST + "?brokerlist='" + BROKER + "'");
env.put("queue.queue", QUEUE);
_context = factory.getInitialContext(env);
_messages = new Message[MSG_COUNT];
_queue = (Queue) _context.lookup("queue");
init();
}