You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@activemq.apache.org by "Dejan Bosanac (JIRA)" <ji...@apache.org> on 2010/12/02 14:10:25 UTC

[jira] Updated: (AMQ-2514) xa jta activemq jboss - xa transaction not set in session

     [ https://issues.apache.org/jira/browse/AMQ-2514?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Dejan Bosanac updated AMQ-2514:
-------------------------------

    Fix Version/s:     (was: 5.4.2)
                   5.5.0

> xa jta activemq jboss - xa transaction not set in session
> ---------------------------------------------------------
>
>                 Key: AMQ-2514
>                 URL: https://issues.apache.org/jira/browse/AMQ-2514
>             Project: ActiveMQ
>          Issue Type: Bug
>          Components: Broker
>    Affects Versions: 5.3.0
>         Environment: JBossTS 4.2.3 SP5, activemq 5.3.0, jdk1.6.0_16, winxp, spring 2.5.6, hp desktop
>            Reporter: Miten Mehta
>             Fix For: 5.5.0
>
>
> JBoss based global transaction does not work with active mq.  The session for say jms though is ActiveMQXASession getting created but its transaction related values are not set at all due to which even after retrieving the message it fails after doing check for whether its transaction context is set or not.  It will give JMS Exception as "Session's XAResource has not been enlisted in a distributed transaction.".
> You can find the thread on nabble at:
> http://old.nabble.com/xa-jta-activemq-jboss-td26515685.html#a26527052
> Note that I have also set the cacheLevel in config below which by default is set with same value in 2.5.6 api.  Setting cache level does not resolve the issue.  The nabble message thread has the earlier configs if one wants to read in complete.
> <?xml version="1.0" encoding="UTF-8"?>
> <beans 
>   xmlns="http://www.springframework.org/schema/beans"
>   xmlns:util="http://www.springframework.org/schema/util"
>   xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
>   xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.0.xsd
>                       http://www.springframework.org/schema/util http://www.springframework.org/schema/util/spring-util-2.0.xsd"
>   >
>   
>  
> <!-- this is the Message Driven POJO (MDP) -->
> <bean id="myMessageListener" class="jmsexample.ExampleListener" />
> <bean id="jndiTemplate" class="org.springframework.jndi.JndiTemplate">
>     <property name="environment">
>       <props>
>         <prop key="java.naming.factory.initial">
>           jmsexample.jndi.ActiveMQInitialContextFactory
>         </prop>
>         <prop key="queue.TEST.Q1">
>           TEST.Q1
>         </prop>
>        
>         <prop key="brokerURL">
>            tcp://localhost:61616
>         </prop>
>       </props>
>     </property>
>   </bean>
>  <bean id="appJmsDestination"
>     class="org.springframework.jndi.JndiObjectFactoryBean">
>     <property name="jndiTemplate">
>       <ref bean="jndiTemplate"/>
>     </property>
>     <property name="jndiName" value="TEST.Q1"/>
>   </bean>
>  
>  <bean id="connectionFactory"
>     class="org.springframework.jndi.JndiObjectFactoryBean">
>     <property name="jndiTemplate">
>       <ref bean="jndiTemplate"/>
>     </property>
>     <property name="jndiName" value="ConnectionFactory"/>
>   </bean>
>  
> <bean id="jmsContainer" class="org.springframework.jms.listener.DefaultMessageListenerContainer">
>     <property name="connectionFactory" ref="connectionFactory"/>
>     <property name="destination" ref="appJmsDestination"/>
>     <property name="messageListener" ref="myMessageListener" />
>     <property name="transactionManager" ref="transactionManager"/>
>    <property name="cacheLevel">
>       <util:constant static-field="org.springframework.jms.listener.DefaultMessageListenerContainer.CACHE_NONE" />
>     </property>
> </bean>
>  
>  <bean id="jbossTransactionManager"
>     class="com.arjuna.ats.internal.jta.transaction.arjunacore.TransactionManagerImple">
>   </bean>
>   <bean id="jbossUserTransaction"
>     class="com.arjuna.ats.internal.jta.transaction.arjunacore.UserTransactionImple"/>
>   <bean id="transactionManager"
>     class="org.springframework.transaction.jta.JtaTransactionManager">
>     <property name="transactionManager">
>       <ref bean="jbossTransactionManager" />
>     </property>
>     <property name="userTransaction">
>       <ref bean="jbossUserTransaction" />
>     </property>
>   </bean>
>    
> </beans> 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.