Atomikos Forum |
|
Hi,
I am setting up an XA test using Atomikos 3.3.1, IBM MQ 6.0 and Spring 2.0. Here is the Spring configuration I'm using: <bean id="mqConnectionFactory" class="com.ibm.mq.jms.MQXAQueueConnectionFactory"> <property name="queueManager" value="MYQMGR"/> <property name="hostName" value="myhost"/> <property name="port" value="1430"/> <property name="channel" value="CH.MYQMGR.SRVC"/> <!-- transportType=1 for TCP client --> <property name="transportType" value="1"/> <property name="clientID" value="mqm"/> </bean> <bean id="atomikosMqConnectionFactory" class="com.atomikos.jms.QueueConnectionFactoryBean"> <property name="xaQueueConnectionFactory" ref="mqConnectionFactory"/> <!-- IMPORTANT: the resourceName MUST contain MQSeries_XA_RMI --> <property name="resourceName" value="My_MQSeries_XA_RMI"/> </bean> <bean id="jmsQueueConnectionFactory" class="org.springframework.jms.connection.UserCredentialsConnectionFactoryAdapter"> <property name="targetConnectionFactory" ref="atomikosMqConnectionFactory"/> <property name="username" value=" "/> <property name="password" value=" "/> </bean> <bean id="inputQueueMessageListenerContainer" class="org.springframework.jms.listener.DefaultMessageListenerContainer" lazy-init="false"> <property name="connectionFactory" ref="jmsQueueConnectionFactory"/> <property name="destination" ref="myQueue"/> <property name="messageListener" ref="myQueueMessageListener"/> <property name="transactionManager" ref="xaTransactionManager"/> <property name="concurrentConsumers" value="1"/> <property name="sessionTransacted" value="true"/> </bean> <bean id="myQueue" class="com.ibm.mq.jms.MQQueue"> <property name="baseQueueManagerName" value="MYQMGR"/> <property name="baseQueueName" value="MYQUEUE"/> </bean> <bean id="myQueueMessageListener" class="com.itp.gt.queue.MQQueueListener"/> My listener simply logs the message to the console but after the first message is logged I am getting the following JMS Exception: javax.jms.JMSException: MQJMS1068: failed to obtain XAResource Can anyone help me figure out what I am doing wrong? Thanks, naor |