3 Replies Latest reply on Jun 12, 2010 2:14 AM by timfox

    Stomp connection to JMS Topics

      In the latest version of Hornetq (built from source yesterday) I am attempting to connect to a JMS topic. In this case the example topic that comes with the default build of Hornetq. The only changes I have made to the configuration is to add the acceptor section so the server accepts Stomp Connections. When I try to send a message to the ExampleTopic, the message never arrives (I am monitoring the topic with Jconsole). Using the same code only changing the destination to the Example Queue, the message arrives fine. I was pretty sure I tested this scenario about before 2.1 was offically released and had sending to the example topic working, is it possible a fix was made that would of broken using jms topics with STOMP?

       

      I am currently using the .NET framework to build my stomp frames, so I do not have an example for you to run (but if neccessary I could pull one together).

      Thanks In Advance

      Matt Peitz

        • 1. Re: Stomp connection to JMS Topics
          timfox

          How do you know the message never "arrives"? (What are you monitoring on JConsole?)

           

          If there are no subscriptions on the topic, the message will go nowhere, that's just how topics work.

          • 2. Re: Stomp connection to JMS Topics

            I guess I misunderstood how topics work. I figured that like queses if there were no subscriptions and never had been the messages would hold until someone actually was there to recieve it. I probably should of been able to see that. Sorry.

            So in order to ensure that a message is actually read from a topic I need to create durable subscriptions before I ever put any messages on to the topic?

            • 3. Re: Stomp connection to JMS Topics
              timfox

              You don't need to create a durable subscription, but you do need to create a subscription.

               

              The JMS spec or Sun JMS tutorial is a good place to understand the ideas behind publish/subscribe in JMS