Embedded ActiveMQ Broker using Spring’s @Configuration
PDFQuick note on how to configure an embedded ActiveMQ server using Spring @Configuration.
1 2 3 4 5 6 7 8 9 10 11 12 13 | @Configuration public class AppConfig { public static final String BROKER_URL = "tcp://localhost:6060"; @Bean public BrokerService broker() throws Exception { BrokerService brokerService = new BrokerService(); brokerService.addConnector(new URI(BROKER_URL)); brokerService.setPersistent(false); return brokerService; } } |
Tags: activemq • spring