14 Replies Latest reply on Jul 5, 2010 9:50 PM by Bill Burke

    Problem with HornetQ in AS 6 M3

    Andrig Miller Apprentice

      I'm trying to test an application that I was running on EAP 5, on AS 6 M3.  I have a single MDB sitting on a queue called replenish.  During the startup of the server, I'm getting the following exception:


      HornetQException[errorCode=105 message=Unable to validate user: null for check type CONSUME for address jms.queue.replenish]
          at org.hornetq.core.protocol.core.impl.ChannelImpl.sendBlocking(ChannelImpl.java:287) [:]
          at org.hornetq.core.client.impl.ClientSessionImpl.internalCreateConsumer(ClientSessionImpl.java:1556) [:]
          at org.hornetq.core.client.impl.ClientSessionImpl.createConsumer(ClientSessionImpl.java:447) [:]
          at org.hornetq.core.client.impl.ClientSessionImpl.createConsumer(ClientSessionImpl.java:392) [:]
          at org.hornetq.core.client.impl.DelegatingSession.createConsumer(DelegatingSession.java:201) [:]
          at org.hornetq.ra.inflow.HornetQMessageHandler.setup(HornetQMessageHandler.java:168) [:]
          at org.hornetq.ra.inflow.HornetQActivation.setup(HornetQActivation.java:287) [:]
          at org.hornetq.ra.inflow.HornetQActivation$SetupActivation.run(HornetQActivation.java:502) [:]
          at org.jboss.resource.work.WorkWrapper.run(WorkWrapper.java:172) [:]
          at org.jboss.threads.SimpleDirectExecutor.execute(SimpleDirectExecutor.java:33) [:]
          at org.jboss.threads.QueueExecutor.runTask(QueueExecutor.java:780) [:]
          at org.jboss.threads.QueueExecutor.access$100(QueueExecutor.java:45) [:]
          at org.jboss.threads.QueueExecutor$Worker.run(QueueExecutor.java:800) [:]
          at java.lang.Thread.run(Thread.java:636) [:1.6.0_18]
          at org.jboss.threads.JBossThread.run(JBossThread.java:122) [:]


      I have the following in hornetq-jms.xml:


      <queue name="replenish">
         <entry name="queue/replenish"/>


      At first I thought, because it says "validate user: null", that I have a user problem, so in looking at the documentation, I found out about the hornetq-users.xml file, so I defined the following in that file:


      <configuration xmlns="urn:hornetq"
                  xsi:schemaLocation="urn:hornetq ../schemas/hornetq-users.xsd ">


          <defaultuser name="guest" password="guest">
              <role name="guest"/>




      I can see this has been picked up, as when I looked at the queue in the admin console, its at the bottom under the roles section, with the user "guest", and it says that guest can send and consume messages.


      That didn't change anything.  The user still appears to be null, and not guest, even though I created guest as the default user.


      Pointers in the right direction would be great.  Thanks.