Package org.apache.activemq.command

Examples of org.apache.activemq.command.ActiveMQQueue


     * @throws Exception
     */
    public static void main(String[] args) throws Exception {
        System.out.println("Connecting to JMS server.");
        factory = new ActiveMQConnectionFactory("tcp://localhost:61616");
        Destination inQueue = new ActiveMQQueue("demo.org.servicemix.source");
        Destination outQueue = new ActiveMQQueue("demo.org.servicemix.output" + (int)(1000*Math.random()));
        requestor = MultiplexingRequestor.newInstance(factory, new JmsProducerConfig(), inQueue, outQueue);

        if (args.length == 0) {
            new JMSClient().run();
        } else {
View Full Code Here


     * @throws Exception
     */
    public static void main(String[] args) throws Exception {
        System.out.println("Connecting to JMS server.");
        factory = new ActiveMQConnectionFactory("tcp://localhost:61616");
        Destination inQueue = new ActiveMQQueue("demo.org.servicemix.source");
        Destination outQueue = new ActiveMQQueue("demo.org.servicemix.output" + (int)(1000*Math.random()));
        requestor = MultiplexingRequestor.newInstance(factory, new JmsProducerConfig(), inQueue, outQueue);

        if (args.length == 0) {
            new JMSClient().run();
        } else {
View Full Code Here

            if (connectionFactory == null) {
                connectionFactory = new ActiveMQConnectionFactory(jmsURL);
            }

            // Inbound connector
            ActiveMQDestination dest = new ActiveMQQueue(INBOUND_PREFIX + broker.getContainer().getName());
            containerConnector = new Connector(dest, this, true);
            containerConnector.start();

            // Outbound connector
            ActiveMQResourceAdapter outboundRa = new ActiveMQResourceAdapter();
View Full Code Here

            return;
        }
        try {
            String key = EndpointSupport.getKey(event.getEndpoint());
            if (!connectorMap.containsKey(key)) {
                ActiveMQDestination dest = new ActiveMQQueue(INBOUND_PREFIX + key);
                Connector connector = new Connector(dest, this, true);
                connector.start();
                connectorMap.put(key, connector);
            }
            // broadcast change to the network
View Full Code Here

            return;
        }
        try {
            String key = event.getComponent().getName();
            if (!connectorMap.containsKey(key)) {
                ActiveMQDestination dest = new ActiveMQQueue(INBOUND_PREFIX + key);
                Connector connector = new Connector(dest, this, true);
                connector.start();
                connectorMap.put(key, connector);
            }
        } catch (Exception e) {
View Full Code Here

                }
            }
            if (me.isTransacted()) {
                me.setTxState(MessageExchangeImpl.TX_STATE_ENLISTED);
            }
            sendJmsMessage(new ActiveMQQueue(destination), me, isPersistent(me), me.isTransacted());
        } catch (JMSException e) {
            log.error("Failed to send exchange: " + me + " internal JMS Network", e);
            throw new MessagingException(e);
        } catch (SystemException e) {
            log.error("Failed to send exchange: " + me + " transaction problem", e);
View Full Code Here

* @version $Revision: 563921 $
*/
public class CompositeQueue extends CompositeDestination {

    public ActiveMQDestination getVirtualDestination() {
        return new ActiveMQQueue(getName());
    }
View Full Code Here

    public void addTopic(String name) throws Exception {
        broker.addDestination(getConnectionContext(broker.getContextBroker()), new ActiveMQTopic(name));
    }

    public void addQueue(String name) throws Exception {
        broker.addDestination(getConnectionContext(broker.getContextBroker()), new ActiveMQQueue(name));
    }
View Full Code Here

        broker.removeDestination(getConnectionContext(broker.getContextBroker()), new ActiveMQTopic(name),
                                 1000);
    }

    public void removeQueue(String name) throws Exception {
        broker.removeDestination(getConnectionContext(broker.getContextBroker()), new ActiveMQQueue(name),
                                 1000);
    }
View Full Code Here

                if (destination instanceof TemporaryQueue) {
                    activeMQDestination = new ActiveMQTempQueue(((Queue)destination).getQueueName());
                } else if (destination instanceof TemporaryTopic) {
                    activeMQDestination = new ActiveMQTempTopic(((Topic)destination).getTopicName());
                } else if (destination instanceof Queue) {
                    activeMQDestination = new ActiveMQQueue(((Queue)destination).getQueueName());
                } else if (destination instanceof Topic) {
                    activeMQDestination = new ActiveMQTopic(((Topic)destination).getTopicName());
                }
            }
        }
View Full Code Here

TOP

Related Classes of org.apache.activemq.command.ActiveMQQueue

Copyright © 2018 www.massapicom. 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.