You are viewing a plain text version of this content. The canonical link for it is here.
Posted to taglibs-dev@jakarta.apache.org by bu...@apache.org on 2005/05/12 15:42:46 UTC

DO NOT REPLY [Bug 34896] New: - Connection Leak in TransactionTagSupport

DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG�
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=34896>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND�
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=34896

           Summary: Connection Leak in TransactionTagSupport
           Product: Taglibs
           Version: 1.0.6
          Platform: PC
        OS/Version: Windows XP
            Status: NEW
          Severity: normal
          Priority: P2
         Component: Standard Taglib
        AssignedTo: taglibs-dev@jakarta.apache.org
        ReportedBy: amcraft@emailplus.org


When wrapping connections in a Transaction tag like:
<sql:transaction dataSource="JNDI.DS">
<sql:query var="query1" >
SELECT * from etc
</sql:query>
<sql:query var="query2" >
SELECT * from etc
</sql:query>
</sql:transaction>

The transaction tag causes a connection leak, the reason is as follows

The nested connection correctly uses the parent connection object. The 
TransactionTagSupport class tries to close the connection in the doFinally() 
method, the problem is before the doFinally() tag is called the release() 
method is called which calls init() which sets the connection object to null 
and hence the doFinally() is unable to close the connection as there is no 
longer a reference to the object and hence the leak.

Proposal would be to remove the init() method from the release() method.

Environment:
Weblogic 8.1 sp3
datasource is sybase looked up by jndi reference.

class:
org.apache.taglibs.standard.tag.common.sql.TransactionTagSupport

-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

---------------------------------------------------------------------
To unsubscribe, e-mail: taglibs-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: taglibs-dev-help@jakarta.apache.org