broker.setBrokerName("TestBroker");
broker.getSystemUsage().setSendFailIfNoSpace(true);
broker.getSystemUsage().getMemoryUsage().setLimit(10 * 1024 * 1024);
KahaPersistenceAdapter persist = new KahaPersistenceAdapter();
persist.setDirectory(new File("/tmp/broker1"));
persist.setMaxDataFileLength(20 * 1024 * 1024);
broker.setPersistenceAdapter(persist);
String brokerUrl = "tcp://localhost:4500";
broker.addConnector(brokerUrl);