Return-Path: X-Original-To: apmail-jackrabbit-dev-archive@www.apache.org Delivered-To: apmail-jackrabbit-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 9FD597858 for ; Tue, 15 Nov 2011 11:43:15 +0000 (UTC) Received: (qmail 54856 invoked by uid 500); 15 Nov 2011 11:43:15 -0000 Delivered-To: apmail-jackrabbit-dev-archive@jackrabbit.apache.org Received: (qmail 54800 invoked by uid 500); 15 Nov 2011 11:43:15 -0000 Mailing-List: contact dev-help@jackrabbit.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@jackrabbit.apache.org Delivered-To: mailing list dev@jackrabbit.apache.org Received: (qmail 54793 invoked by uid 99); 15 Nov 2011 11:43:15 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 15 Nov 2011 11:43:15 +0000 X-ASF-Spam-Status: No, hits=-2001.2 required=5.0 tests=ALL_TRUSTED,RP_MATCHES_RCVD X-Spam-Check-By: apache.org Received: from [140.211.11.116] (HELO hel.zones.apache.org) (140.211.11.116) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 15 Nov 2011 11:43:12 +0000 Received: from hel.zones.apache.org (hel.zones.apache.org [140.211.11.116]) by hel.zones.apache.org (Postfix) with ESMTP id F3A08845ED for ; Tue, 15 Nov 2011 11:42:51 +0000 (UTC) Date: Tue, 15 Nov 2011 11:42:51 +0000 (UTC) From: "Boris Pruessmann (Updated) (JIRA)" To: dev@jackrabbit.apache.org Message-ID: <1498631601.30567.1321357372034.JavaMail.tomcat@hel.zones.apache.org> In-Reply-To: <1036526867.30552.1321357251750.JavaMail.tomcat@hel.zones.apache.org> Subject: [jira] [Updated] (JCR-3148) Using transactions still leads to memory leak MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/JCR-3148?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Boris Pruessmann updated JCR-3148: ---------------------------------- Status: Patch Available (was: Open) Attached patch file > Using transactions still leads to memory leak > --------------------------------------------- > > Key: JCR-3148 > URL: https://issues.apache.org/jira/browse/JCR-3148 > Project: Jackrabbit Content Repository > Issue Type: Bug > Components: transactions > Affects Versions: 2.2.5 > Reporter: Boris Pruessmann > Attachments: XASessionImpl.patch > > > This is a result of the way that JCR-395 was fixed. If you look at the code, you'll see that txGlobal.remove(xid) is called as the last statement in both XASessionImpl.commit() and XASessionImpl.rollback(). However, in both methods an exception could be thrown either as a result of calling tx.commit() (or tx.prepare()) and tx.rollback(). > As a result, the transaction will not be removed from txGlobals whenever the commit or the rollback has failed for any reason. My suggestion would be to move the txGlobal.remove(xid) into a finally block. -- 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