9 Replies Latest reply on Dec 9, 2010 7:44 AM by superDev superDev

    hornetQ configuration in JBoss 6

    superDev superDev Newbie

      I have an EE project that defines JMS service in application  scope, In Jboss 5. the JMS service and queue was defined in my-jms-servie.xml file under myApplication.ear

       

      <server>

       

          <!-- Version for Boss messaging, JBoss 5 GA -->
        
          <mbean code="org.jboss.jms.server.destination.QueueService" name="jboss.messaging.destination:service=Queue,name=myQueue"
              xmbean-dd="xmdesc/Queue-xmbean.xml">
             
              <depends optional-attribute-name="ServerPeer">jboss.messaging:service=ServerPeer</depends>
              <depends>jboss.messaging:service=PostOffice</depends>
             
              <attribute name="MessageCounterHistoryDayLimit">-1</attribute>
          </mbean>
        

       

      </server>

       

      and in myApplication.ear/META-INF/jboss-app.xml file, I add this as a module.

      <jboss-app>
      ...

         <module>
              <service>my-jms-servie.xml</service>
          </module>
      ...

      </jboss-app> 

       

      When I tried to deploy this project to JBoss 6.0, I could not succeed configuring JMS service for hornetQ.

       

      I changed the content of my-jms-service.xml to this:

      <configuration xmlns="urn:hornetq"
                  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
                  xsi:schemaLocation="urn:hornetq /schema/hornetq-jms.xsd">

       

         <connection-factory name="ConnectionFactory">
            <connectors>
               <connector-ref connector-name="netty"/>
            </connectors>
         <entries>
               <entry name="ConnectionFactory"/>
            </entries>
         </connection-factory>

       


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

      </configuration>

       

      But I will get the following exceptions:

       

      RROR [org.jboss.profileservice.dependency.ProfileDeployAction] Failed to add deployment: myApplication.ear: org.jboss.deployers.spi.DeploymentException: Exception determining structure: AbstractVFSDeployment(myApplication.ear)
          at org.jboss.deployers.spi.DeploymentException.rethrowAsDeploymentException(DeploymentException.java:49) [:2.2.0.Alpha8]
          at org.jboss.deployers.structure.spi.helpers.AbstractStructuralDeployers.determineStructure(AbstractStructuralDeployers.java:85) [:2.2.0.Alpha8]

       

      I wonder if anyone knows how to do this. Thanks a lot in advance!