Examples of ActiveMQQueue


Examples of org.apache.activemq.command.ActiveMQQueue

    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

Examples of org.apache.activemq.command.ActiveMQQueue

        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

Examples of org.apache.activemq.command.ActiveMQQueue

                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

Examples of org.apache.activemq.command.ActiveMQQueue

    // SecurityAdminMBean interface
    // -------------------------------------------------------------------------

    public void addQueueRole(String queue, String operation, String role) {
        addDestinationRole(new ActiveMQQueue(queue), operation, role);
    }
View Full Code Here

Examples of org.apache.activemq.command.ActiveMQQueue

    public void addTopicRole(String topic, String operation, String role) {
        addDestinationRole(new ActiveMQTopic(topic), operation, role);
    }

    public void removeQueueRole(String queue, String operation, String role) {
        removeDestinationRole(new ActiveMQQueue(queue), operation, role);
    }
View Full Code Here

Examples of org.apache.activemq.command.ActiveMQQueue

    }

    @Test
    public void testManualRequestReply() throws Exception {
        // send using pure JMS API to set a custom JMSReplyTo
        jms.send(new ActiveMQQueue("foo"), new MessageCreator() {
            public Message createMessage(Session session) throws JMSException {
                TextMessage msg = session.createTextMessage("Hello World");
                msg.setJMSReplyTo(new ActiveMQQueue("bar"));
                return msg;
            }
        });

        latch.await(5, TimeUnit.SECONDS);
View Full Code Here

Examples of org.apache.activemq.command.ActiveMQQueue

    public static void main(String[] args) {
        junit.textui.TestRunner.run(suite());
    }

    public void initCombos() {
        addCombinationValues("destination", new Object[] {new ActiveMQQueue("TEST.QUEUE"), new ActiveMQTopic("TEST.TOPIC")});
    }
View Full Code Here

Examples of org.apache.activemq.command.ActiveMQQueue

        broker.setPersistenceAdapter(adapter);
        PolicyEntry policy = new PolicyEntry();
        policy.setPrioritizedMessages(prioritizeMessages);
        policy.setUseCache(useCache);
        PolicyMap policyMap = new PolicyMap();
        policyMap.put(new ActiveMQQueue("TEST"), policy);
        policyMap.put(new ActiveMQTopic("TEST"), policy);
        broker.setDestinationPolicy(policyMap);
        broker.start();
        broker.waitUntilStarted();
       
View Full Code Here

Examples of org.apache.activemq.command.ActiveMQQueue

    public void initCombosForTestQueues() {
        addCombinationValues("useCache", new Object[] {new Boolean(true), new Boolean(false)});
    }
   
    public void testQueues() throws Exception {
        ActiveMQQueue queue = (ActiveMQQueue)sess.createQueue("TEST");

        ProducerThread lowPri = new ProducerThread(queue, MSG_NUM, LOW_PRI);
        ProducerThread highPri = new ProducerThread(queue, MSG_NUM, HIGH_PRI);
       
        lowPri.start();
View Full Code Here

Examples of org.apache.activemq.command.ActiveMQQueue

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

    public void addQueue(String name) throws Exception {
        broker.getContextBroker().addDestination(BrokerSupport.getConnectionContext(broker.getContextBroker()), new ActiveMQQueue(name),true);
    }
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.