Willem Jan Gerritsen created AMQ-3899:
-----------------------------------------

             Summary: XAQueueConnectionFactory is not able to create normal 
QueueConnections
                 Key: AMQ-3899
                 URL: https://issues.apache.org/jira/browse/AMQ-3899
             Project: ActiveMQ
          Issue Type: Bug
          Components: JMS client
    Affects Versions: 5.6.0
            Reporter: Willem Jan Gerritsen


The ActiveMQXAConnectionFactory has a method: QueueConnection 
createQueueConnection(). This method returns an instance of 
ActiveMQXAConnection.

This connection cannot handle transacted sessions:
{code}
        @Test
        public void create_message_producer_and_send() throws Exception {
                QueueSession queueSession = 
queueConnection.createQueueSession(true, Session.AUTO_ACKNOWLEDGE);
                MessageProducer producer = 
queueSession.createProducer(queueSession.createQueue(queueName));
                BytesMessage jmsMessage = queueSession.createBytesMessage();
                jmsMessage.writeBytes("Hello world".getBytes());
                producer.send(jmsMessage);
                queueSession.commit(); // --> fail with 
TransactionInProgressException
        }
{code}

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to