3 Replies Latest reply on May 29, 2012 11:15 AM by Clebert Suconic

    How Do I Configure HornetQ With HermesJMS?

    Johnny Boy Newbie

      The wiki about using HermesJMS with HornetQ (http://community.jboss.org/wiki/UsingHermesJMSWithHornetQ) just links to instructions on the Hermes JMS site.


      However, the images on that site are broken.


      I found an old copy on the wayback machine if someone wants to put the details on the wiki here instead of just linking.



      I am running the standalone version of HornetQ.

      Is JNDI the only option to connect?


      I can apparently connect like this but when I try to create a queue and browse it I get the error javax.jms.JMSException: There is no queue with name Test.

      Have I connected properly?


      JNDI InitialContext

      loader = HornetQ

      initialContextFactory org.jnp.interfaces.NamingContextFactory

      providerURL jnp://localhost:1099


      Session is auto-created from the context as:

      Class hermes.JNDIConnectionFactory

      binding ConnectionFactory

      initialContextFactory org.jnp.interfaces.NamingContextFactory

      providerURL jnp://localhost:1099

        • 1. Re: How Do I Configure HornetQ With HermesJMS?
          Yong Hao Gao Master

          How do you create the queue? Did get more error info like stack trace along with the JMSException?



          • 2. Re: How Do I Configure HornetQ With HermesJMS?
            Johnny Boy Newbie

            I created the queue from Hermes with:

            Actions -> New -> Add Queue

            Name = Test

            Domain = Queue

            Durable = False


            The full stack trace is:


            javax.jms.JMSException: There is no queue with name Test
            at org.hornetq.jms.client.HornetQSession.createQueue(HornetQSession.java:407)
            at hermes.impl.jms.SimpleDestinationManager.createDesintaion(SimpleDestinationManager.java:60)
            at hermes.impl.JNDIDestinationManager.createDesintaion(JNDIDestinationManager.java:105)
            at hermes.impl.jms.SimpleDestinationManager.getDestination(SimpleDestinationManager.java:137)
            at hermes.impl.jms.AbstractSessionManager.getDestination(AbstractSessionManager.java:387)
            at hermes.impl.DefaultHermesImpl.getDestination(DefaultHermesImpl.java:323)
            at hermes.browser.tasks.BrowseDestinationTask.invoke(BrowseDestinationTask.java:122)
            at hermes.browser.tasks.TaskSupport.run(TaskSupport.java:175)
            at hermes.browser.tasks.ThreadPool.run(ThreadPool.java:170)
            at java.lang.Thread.run(Thread.java:662)


            • 3. Re: How Do I Configure HornetQ With HermesJMS?
              Clebert Suconic Master

              There's something wrong with the Hermes integration. This method here is used to create the Queue Object, not actually creating the queue:





              However, I believe some implementations will create the actual queue after it.