2 Replies Latest reply: Jul 8, 2012 9:32 AM by Venkat Ramana RSS

QueueSession commit() of MQ Queue throwing Exception

Venkat Ramana Newbie

Hello all,


I am trying to configure (migrating from Websphere to Jboss), MQ queues on my JBoss 5.1.1 app server. I am getting following exception, your help is highly appreciated.


Application throwing the following exception while trying to commit the QueueSession object.


Pre-configuration steps:


1.            Copied com.ibm.mqetclient.jar into \jboss-eap\jboss-as\server\default\lib\


2.            Copied  wmq.jmsra.rar  into \jboss-eap\jboss-as\server\default\deploy\


3.            defined queue and connection factory definitions in *-ds.xml


4.            Modified the ra.xml as needed to the QueueConnection factory


5.            MQ resource adapter setting is CLIENT mode and using QueueConnectionFactory in ra.xml


6.            Created/defined connection factory in *-ds.xml as <tx-connection-factory>......</tx-connection-factory>



Session obtaining as follows:


Javax.jms.QueueConnection connection = factory.createQueueConnection();

Javax.jms.QueueSession session = connection.createQueueSession(true, Session.AUTO_ACKNOWLEDGE);

QueueReceiver reciever = session.createReceiver(getRecieverQueue());   // Queue JNDI name


…… ……. ……. …….



Exception Stacktrace:

15:59:14,604 INFO  [STDOUT] - MH: (47985) <ITListener>: Got Throwable inside the loop:::::::::::javax.jms.IllegalStateException: MQJMS1019: invalid operation for non-transacted session

15:59:15,276 ERROR [STDERR] javax.jms.IllegalStateException: MQJMS1019: invalid operation for non-transacted session

15:59:15,276 ERROR [STDERR]             at com.ibm.mq.jms.MQSession.commitQ(MQSession.java:3843)

15:59:15,276 ERROR [STDERR]             at com.ibm.mq.jms.MQQueueSession.commit(MQQueueSession.java:154)

15:59:15,276 ERROR [STDERR]             at com.ibm.mq.connector.outbound.SessionWrapper.commit(SessionWrapper.java:197)

15:59:15,276 ERROR [STDERR]             at com.xxxxxx.xxx.xxx.msghub.adapters.MHITListener.startMQReciever(MHITListener.java:219)

15:59:15,276 ERROR [STDERR]             at com.xxxxxxx.xxx.xxx.msghub.adapters.MHITListener$1.run(MHITListener.java:115)

15:59:15,276 ERROR [STDERR]             at java.util.TimerThread.mainLoop(Unknown Source)

15:59:15,276 ERROR [STDERR]             at java.util.TimerThread.run(Unknown Source)



Note: My Company has the license of com.ibm.mqetclient.jar and wmq.jmsra.rar.