Package org.activemq.broker.impl

Examples of org.activemq.broker.impl.BrokerContainerImpl.start()


        MulticastDiscoveryAgent agent = new MulticastDiscoveryAgent(getClass().getName());
        container.setDiscoveryAgent(agent);
        String url = "tcp://localhost:0";
        container.addConnector(url);
        container.addNetworkConnector(new DiscoveryNetworkConnector(container));
        container.start();
        //embedded brokers are resolved by url - so make url unique
        //this confused me tests for a while :-)
        return new ActiveMQConnectionFactory(container,"vm://"+brokerName);
    }
View Full Code Here


                URIHelper helper = new URIHelper(brokerConnectorURI);
                brokerConnector = new BrokerConnectorImpl(container, helper.getNext(), wireFormat);
                while (helper.hasNext()) {
                    new BrokerConnectorImpl(container, helper.getNext(), wireFormat);
                }
                container.start();
            }
            return brokerConnector;
        }
        catch (Exception e) {
            e.printStackTrace();
View Full Code Here

        // Start internal vm protocoll
        BrokerConnectorImpl vmConnector = new BrokerConnectorImpl(container, "vm://localhost", new DefaultWireFormat());
        BrokerConnectorImpl tcpConnector = new BrokerConnectorImpl(container, "tcp://localhost:9100", new DefaultWireFormat());

        // start activemq broker
        container.start();
        return container;
    }

}
View Full Code Here

        MulticastDiscoveryAgent agent = new MulticastDiscoveryAgent(getClass().getName());
        container.setDiscoveryAgent(agent);
        String url = "tcp://localhost:0";
        container.addConnector(url);
        container.addNetworkConnector(new DiscoveryNetworkConnector(container));
        container.start();
        //embedded brokers are resolved by url - so make url unique
        //this confused me tests for a while :-)
        return new ActiveMQConnectionFactory(container,"vm://"+brokerName);
    }
View Full Code Here

                URIHelper helper = new URIHelper(brokerConnectorURI);
                brokerConnector = new BrokerConnectorImpl(container, helper.getNext(), wireFormat);
                while (helper.hasNext()) {
                    new BrokerConnectorImpl(container, helper.getNext(), wireFormat);
                }
                container.start();
            }
            return brokerConnector;
        }
        catch (Exception e) {
            e.printStackTrace();
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.