Package org.codehaus.activemq.message

Examples of org.codehaus.activemq.message.ActiveMQTopic


    public void testMatchConnection(){
        String destName = "foo.bar";
        ConnectionInfo info = new ConnectionInfo();
       
       
        ActiveMQTopic advisoryDest = new ActiveMQTopic(ActiveMQDestination.CONNECTION_ADVISORY_PREFIX + destName);
        ConsumerInfo advisory = new ConsumerInfo();
        advisory.setDestination(advisoryDest);
        AdvisorySupport test = new AdvisorySupport();
        assertTrue(test.matchConnection(advisory, info));
    }
View Full Code Here


    super.setUp();
    this.consumerId = "testConsumerId";
    this.clientId = "testclientId";
    this.subscriberName = "testsubscriberName";
    this.selector = "testselector";
    this.destination = new ActiveMQTopic("testtopic");
    this.startTime = System.currentTimeMillis();
    this.started = true;
    this.consumerNo = 3;
        this.prefetchNumber = 13;
  }
View Full Code Here

    protected void setUp() throws Exception {
        super.setUp();
        this.id = 3445;
        this.producerId = "testProducerId";
        this.clientId = "testclientId";
        this.destination = new ActiveMQTopic("testtopic");
        this.startTime = System.currentTimeMillis();
        this.started = true;
    }
View Full Code Here

            info.setClientId(brokerClientID);
            info.setStarted(true);
            client.consumeConnectionInfo(info);

            ConsumerInfo consumerInfo = new ConsumerInfo();
            consumerInfo.setDestination(new ActiveMQTopic(">"));
            consumerInfo.setNoLocal(true);
            consumerInfo.setClientId(brokerClientID);
            consumerInfo.setConsumerId(idGenerator.generateId());
            consumerInfo.setStarted(true);
            client.consumeConsumerInfo(consumerInfo);
View Full Code Here

     */
    public void start() throws JMSException{
        if (started.commit(false,true)){
            session = connection.createSession(false,Session.AUTO_ACKNOWLEDGE);
            String advisoryName = ActiveMQDestination.CONNECTION_ADVISORY_PREFIX;
            Destination advisoryDestination = new ActiveMQTopic(advisoryName);
            MessageConsumer consumer = session.createConsumer(advisoryDestination);
            consumer.setMessageListener(this);
        }
    }
View Full Code Here

     * @throws JMSException if the session fails to create a topic due to some internal error.
     * @since 1.1
     */
    public Topic createTopic(String topicName) throws JMSException {
        checkClosed();
        return new ActiveMQTopic(topicName);
    }
View Full Code Here

    // Implementation methods
    //-------------------------------------------------------------------------
    protected MessageContainer createContainer(String destinationName) throws JMSException {
        TopicMessageContainer topicMessageContainer = persistenceAdapter.createTopicMessageContainer(destinationName);
        destinationMap.put(new ActiveMQTopic(destinationName), topicMessageContainer);
        return topicMessageContainer;
    }
View Full Code Here

        destinationMap.put(new ActiveMQTopic(destinationName), topicMessageContainer);
        return topicMessageContainer;
    }

    protected Destination createDestination(String destinationName) {
        return new ActiveMQTopic(destinationName);
    }
View Full Code Here

        return filterFactory.createFilter(createDestination(subject), selector);
    }

    protected ActiveMQDestination createDestination(String subject) {
        if (isTopic()) {
            return new ActiveMQTopic(subject);
        }
        else {
            return new ActiveMQQueue(subject);
        }
    }
View Full Code Here

  protected void setUp() throws Exception {
    super.setUp();
    this.jmsMessageID = "testid";
    this.jmsClientID = "testclientid";
    this.jmsCorrelationID = "testcorrelationid";
    this.jmsDestination = new ActiveMQTopic("test.topic");
    this.jmsReplyTo = new ActiveMQTemporaryTopic("test.replyto.topic");
    this.jmsDeliveryMode = DeliveryMode.NON_PERSISTENT;
    this.jmsRedelivered = true;
    this.jmsType = "test type";
    this.jmsExpiration = 100000;
View Full Code Here

TOP

Related Classes of org.codehaus.activemq.message.ActiveMQTopic

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.