2 Replies Latest reply on Jan 14, 2010 7:34 AM by Adrian Brock

    Include XA aware connection factory with EAR

    Alexander Hartner Expert

      I would like to bundle the definition of an XA aware connection factory with my applications EAR. I am already including the destination need by the MDBs using a abc-service.xml file. However I would like to create a xa-transaction aware connection factory similar to those defined in hajndi-jms-ds.xml. I tried included a separate xyz-services.xml file with the following content:


      <?xml version="1.0" encoding="UTF-8"?>


        <!-- JMS XA Resource adapter, use this to get transacted JMS in beans -->







          <config-property name="SessionDefaultType" type="java.lang.String">javax.jms.Topic</config-property>

          <config-property name="JmsProviderAdapterJNDI" type="java.lang.String">java:/DefaultJMSProvider</config-property>







      However this didn't work. I know that I could define a connection factory using the following in my abc-service.xml file which is included in my ear.


      <mbean code="org.jboss.jms.server.connectionfactory.ConnectionFactory"



            <depends optional-attribute-name="ServerPeer">




      however I am not sure if these will have the same transactional properties as those connection factories defined in hajndi-jms-ds.xml. Any information on the differences between the connection factories defined in hajndi-jms-ds.xml and those in jboss-messaging.sar/connection-factories-service.xml / abc-service.xml would help as well. Ideally I am looking for a method to define a connection factory with the same properties as JmsXA  and include that within my EAR file.


      Thanks in advance