1 Reply Latest reply on Jun 15, 2009 12:18 PM by anil.saldhana

    local tx transaction or xa transaction datasource?

    jeff.yuchang

      In the JBoss idm distribution deployment. I am using the xa datasource as default, like following one as mysql one.

      <?xml version="1.0" encoding="UTF-8"?>
      <datasources>
      
       <xa-datasource>
       <jndi-name>jbossidmDS</jndi-name>
      
       <xa-datasource-class>com.mysql.jdbc.jdbc2.optional.MysqlXADataSource</xa-datasource-class>
       <xa-datasource-property name="URL">@jdbc.url@</xa-datasource-property>
       <user-name>@jdbc.username@</user-name>
       <password>@jdbc.password@</password>
      
      
       <!-- reduce isolation from the default level (repeatable read) -->
       <transaction-isolation>TRANSACTION_READ_COMMITTED</transaction-isolation>
       <!-- separate connections used with and without JTA transaction -->
       <no-tx-separate-pools />
       <!-- disable transaction interleaving -->
       <track-connection-by-tx />
      
       <!-- leverage mysql integration features -->
       <exception-sorter-class-name>
       com.mysql.jdbc.integration.jboss.ExtendedMysqlExceptionSorter
       </exception-sorter-class-name>
       <valid-connection-checker-class-name>
       com.mysql.jdbc.integration.jboss.MysqlValidConnectionChecker
       </valid-connection-checker-class-name>
      
       <!-- corresponding type-mapping in conf/standardjbosscmp-jdbc.xml -->
       <metadata>
       <type-mapping>mySQL</type-mapping>
       </metadata>
       </xa-datasource>
      
      </datasources>
      


      Was wondering is it better that we used the local-tx datasource as default, or use the xa-datasource as now.

      What do you think?

      Thanks
      Jeff