Calling method rollback() on userTransaction in MessageDrivenBean doesn't make an effect, if this MDB is defined with
@TransactionManagement(value = TransactionManagementType.BEAN)
2 tests in TCK affected:
Test8 and Test9 in
https://jenkins.mw.lab.eng.bos.redhat.com/hudson/job/tck5-eap5x-jdk6-jms-ibmmq/18/testReport/unknownTestSuite.0/packageTests/com.sun.ts.tests.jms.ee.mdb.xa/
Impact for customers
Incorrect behaviour of userTransactions.
Reproducer info
failed test org.jboss.as.test.ibm.mq.tck.UserTransactionBmtTestCase in
https://jenkins.mw.lab.eng.bos.redhat.com/hudson/view/EAP5/view/IBM-MQ/job/_eap5-ibm-mq-tck-failures-reproducers/
Link to reproducers execution:
https://docspace.corp.redhat.com/docs/DOC-124332#rep
Links for info how to setup IBM MQ locally
https://docspace.corp.redhat.com/docs/DOC-114804#qi
More detailed description
1)appclient sends message in input destination(queue or topic) and waits for a message from output queue;
2)deployed MDB gets message from input destination and tries to send message to output queue inside UserTransaction this way:
// Obtain the transaction demarcation interface. UserTransaction ut = mdc.getUserTransaction(); // start a transaction ut.begin(); // send a message to MDB_QUEUE_REPLY. JmsUtil.sendTestResults("xaTest8",false,qSession,queueR); // rollback the message ut.rollback(); ut.begin(); // send a message to MDB_QUEUE_REPLY JmsUtil.sendTestResults("xaTest8",true,qSession,queueR); // rollback the message ut.commit();
3) expected, that only second message will be send;
4) result: both messages are sent, test fails
- is related to
-
JBEAP-2344 UserTransaction commit(), rollback() closes connection in Websphere MQ 7.5
- Closed