Package org.apache.activemq.command

Examples of org.apache.activemq.command.ActiveMQTempQueue


        return info;
    }

    protected void populateObject(Object object) throws Exception {
        super.populateObject(object);
        ActiveMQTempQueue info = (ActiveMQTempQueue)object;

    }
View Full Code Here


        case QUEUE:
            return new ActiveMQQueue(name);
        case TOPIC:
            return new ActiveMQTopic(name);
        case TEMP_QUEUE:
            return new ActiveMQTempQueue(name);
        case TEMP_TOPIC:
            return new ActiveMQTempTopic(name);
        default:
            throw new IllegalArgumentException("Not in the valid destination format");
        }
View Full Code Here

        List<ActiveMQDestination> dests = new ArrayList<ActiveMQDestination>();
        config.setDynamicallyIncludedDestinations(dests);
        assertEquals(AdvisorySupport.CONSUMER_ADVISORY_TOPIC_PREFIX + ">", config.getDestinationFilter());
        dests.add(new ActiveMQQueue("TEST.>"));
        dests.add(new ActiveMQTopic("TEST.>"));
        dests.add(new ActiveMQTempQueue("TEST.>"));
        String prefix = AdvisorySupport.CONSUMER_ADVISORY_TOPIC_PREFIX;
        assertEquals(prefix + "Queue.TEST.>," + prefix + "Topic.TEST.>", config.getDestinationFilter());
    }
View Full Code Here

        // lets subscribe to a personal inbox for replies

        // Check if Destination info is of temporary type.
        if (inboxDestination == null) {
            inboxDestination = new ActiveMQTempQueue(connectionInfo.getConnectionId(), tempDestinationIdGenerator.getNextSequenceId());

            DestinationInfo info = new DestinationInfo();
            info.setConnectionId(connectionInfo.getConnectionId());
            info.setOperationType(DestinationInfo.ADD_OPERATION_TYPE);
            info.setDestination(inboxDestination);
View Full Code Here

            if (destination instanceof ActiveMQDestination) {
                return (ActiveMQDestination)destination;

            } else {
                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) {
View Full Code Here

        // Check if Destination info is of temporary type.
        ActiveMQTempDestination dest;
        if (topic) {
            dest = new ActiveMQTempTopic(info.getConnectionId(), tempDestinationIdGenerator.getNextSequenceId());
        } else {
            dest = new ActiveMQTempQueue(info.getConnectionId(), tempDestinationIdGenerator.getNextSequenceId());
        }

        DestinationInfo info = new DestinationInfo();
        info.setConnectionId(this.info.getConnectionId());
        info.setOperationType(DestinationInfo.ADD_OPERATION_TYPE);
View Full Code Here

        case QUEUE:
            return new ActiveMQQueue(name);
        case TOPIC:
            return new ActiveMQTopic(name);
        case TEMP_QUEUE:
            return new ActiveMQTempQueue(name);
        case TEMP_TOPIC:
            return new ActiveMQTempTopic(name);
        default:   
            throw new IllegalArgumentException("Not in the valid destination format");
        }
View Full Code Here

        ActiveMQConnectionFactory sendFactory = createConnectionFactory(a);
        ActiveMQConnection sendConnection = createConnection(sendFactory);

        ActiveMQSession sendSession = (ActiveMQSession)sendConnection.createSession(false, Session.AUTO_ACKNOWLEDGE);
        MessageProducer producer = sendSession.createProducer(sendQ);
        ActiveMQTempQueue realReplyQ = (ActiveMQTempQueue) sendSession.createTemporaryQueue();
        TextMessage message = sendSession.createTextMessage("1");
        message.setJMSReplyTo(realReplyQ);
        producer.send(message);
        LOG.info("request sent");
View Full Code Here

     * @since 1.1
     */
    public Queue createQueue(String queueName) throws JMSException {
        checkClosed();
        if (queueName.startsWith(ActiveMQDestination.TEMP_DESTINATION_NAME_PREFIX)) {
            return new ActiveMQTempQueue(queueName);
        }
        return new ActiveMQQueue(queueName);
    }
View Full Code Here

        return false;
    }

    private ActiveMQDestination createTempQueue() {
        ActiveMQDestination rc;
        rc = new ActiveMQTempQueue(connectionId, nextTempDestinationId++);
        DestinationInfo info = new DestinationInfo();
        info.setConnectionId(connectionId);
        info.setOperationType(DestinationInfo.ADD_OPERATION_TYPE);
        info.setDestination(rc);
        sendToActiveMQ(info, null);
View Full Code Here

TOP

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

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.