Return-Path: X-Original-To: apmail-activemq-dev-archive@www.apache.org Delivered-To: apmail-activemq-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 92804D2C7 for ; Tue, 26 Jun 2012 11:54:45 +0000 (UTC) Received: (qmail 8605 invoked by uid 500); 26 Jun 2012 11:54:45 -0000 Delivered-To: apmail-activemq-dev-archive@activemq.apache.org Received: (qmail 8368 invoked by uid 500); 26 Jun 2012 11:54:45 -0000 Mailing-List: contact dev-help@activemq.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@activemq.apache.org Delivered-To: mailing list dev@activemq.apache.org Received: (qmail 8334 invoked by uid 99); 26 Jun 2012 11:54:44 -0000 Received: from issues-vm.apache.org (HELO issues-vm) (140.211.11.160) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 26 Jun 2012 11:54:44 +0000 Received: from isssues-vm.apache.org (localhost [127.0.0.1]) by issues-vm (Postfix) with ESMTP id 9002914035F for ; Tue, 26 Jun 2012 11:54:43 +0000 (UTC) Date: Tue, 26 Jun 2012 11:54:42 +0000 (UTC) From: "Willem Jan Gerritsen (JIRA)" To: dev@activemq.apache.org Message-ID: <1041287855.56106.1340711683592.JavaMail.jiratomcat@issues-vm> In-Reply-To: <1514958069.56101.1340711443909.JavaMail.jiratomcat@issues-vm> Subject: [jira] [Updated] (AMQ-3899) XAQueueConnectionFactory is not able to create normal QueueConnections MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/AMQ-3899?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Willem Jan Gerritsen updated AMQ-3899: -------------------------------------- Description: 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} Our use-case is to instantiate a single queueconnectionfactory, which would be able to provide both normal (transacted) and XA connections. So that when we are sure that when we have only messaging in our transaction, that then we don't need to bother about initiating an XA transaction. was: 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} > 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} > Our use-case is to instantiate a single queueconnectionfactory, which would be able to provide both normal (transacted) and XA connections. So that when we are sure that when we have only messaging in our transaction, that then we don't need to bother about initiating an XA transaction. -- 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