commons-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Frank Hefter (JIRA)" <>
Subject [jira] Commented: (DBCP-233) Allow connection, statement, and result set to be closed multiple times
Date Thu, 07 Feb 2008 09:47:07 GMT


Frank Hefter commented on DBCP-233:

I patched a 1.2.2 version with the above but had ongoing problems with "already closed exceptions".
In addition I would suggest to remove in PoolableConnection line84: the "throw new ..." clause
(within the isClosed area).
After this change my application is stable now.

I'm a little concerned about the comment "// XXX should be guarded to happen at most once"
But this is done by the try catch surrounding the invalidateObject(this) and the exception
thrown didn't help anyway.

Sorry I had no chance to make a patch file or test this.

> Allow connection, statement, and result set to be closed multiple times
> -----------------------------------------------------------------------
>                 Key: DBCP-233
>                 URL:
>             Project: Commons Dbcp
>          Issue Type: Improvement
>            Reporter: Dain Sundstrom
>             Fix For: 1.3
>         Attachments: CloseTwice.patch
> This patch allows Connection, Statement, PreparedStatement, CallableStatement and ResultSet
to be closed multiple times.  The first time close is called the resource is closed and any
subsequent calls have no effect.  This behavior is required as per the JavaDocs for these
classes.  The patch adds tests for closing all types multiple times and updates any tests
that incorrectly assert that a resource can be closed more then once.
> This patch fixes DBCP-134 and DBCP-3

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

View raw message