[jira] Updated: (DBCP-11) [dbcp] stmt.getConnection() != Connection used to create the statement

2007-07-18 Thread Dain Sundstrom (JIRA)

 [ 
https://issues.apache.org/jira/browse/DBCP-11?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Dain Sundstrom updated DBCP-11:
---

Attachment: back-pointers.patch

This patch assures that all all returned Statements, PreparedStatements, 
CallableStatements and ResultSets are wrapped with a delegating object, which 
already properly handle the back pointers for Connection and Statement.  This 
patch includes an extensive test to assure that the *same* object used to 
create the statement or result set is returned from either the getConnection() 
or getStatementMethod().  


> [dbcp] stmt.getConnection() != Connection used to create the statement
> --
>
> Key: DBCP-11
> URL: https://issues.apache.org/jira/browse/DBCP-11
> Project: Commons Dbcp
>  Issue Type: Bug
>Affects Versions: 1.2
> Environment: Operating System: other
> Platform: All
>Reporter: Alexander Rupsch
> Fix For: 1.3
>
> Attachments: back-pointers.patch
>
>
> Hi,
> I'm not an expert in implementing connection pools or jdbc itself. But 
> shouldn't
> the following code work?
> Connection con = pool.getConnection()
> PreparedStatement ps = con.prepareStatement()
> con.equals(ps.getConnection) // returns false!
> Ok, I don't need it to be equal, but the following also does not work:
> ps.getConnection().close()
> con.isClosed() // is false!!!
> That means, if I have a Statment and want to close its connection, I have to
> remember the conncetion. Is that the requested behavior? Because of this my 
> pool
> is running over.
> The java.sql API says that Statment.getConnection() has to be the connection
> which created the statement.

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


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



[jira] Updated: (DBCP-11) [dbcp] stmt.getConnection() != Connection used to create the statement

2006-09-24 Thread Phil Steitz (JIRA)
 [ http://issues.apache.org/jira/browse/DBCP-11?page=all ]

Phil Steitz updated DBCP-11:


  Bugzilla Id:   (was: 36077)
Fix Version/s: 1.3
   (was: 1.2.2)

Changing the fix version to 1.3.  We may in fact decide on WONTFIX eventually, 
but I want to hold off on that judgement until we have reworked close() 
systematically.

If we interpret the spec to mean that Statment.getConnection()  has to return 
the physical connection that created the statement, this is in general *not* 
going to be equal to the connection object that the user has a reference to and 
may also be open when the user's connection is closed.

> [dbcp] stmt.getConnection() != Connection used to create the statement
> --
>
> Key: DBCP-11
> URL: http://issues.apache.org/jira/browse/DBCP-11
> Project: Commons Dbcp
>  Issue Type: Bug
>Affects Versions: 1.2 Final
> Environment: Operating System: other
> Platform: All
>Reporter: Alexander Rupsch
> Fix For: 1.3
>
>
> Hi,
> I'm not an expert in implementing connection pools or jdbc itself. But 
> shouldn't
> the following code work?
> Connection con = pool.getConnection()
> PreparedStatement ps = con.prepareStatement()
> con.equals(ps.getConnection) // returns false!
> Ok, I don't need it to be equal, but the following also does not work:
> ps.getConnection().close()
> con.isClosed() // is false!!!
> That means, if I have a Statment and want to close its connection, I have to
> remember the conncetion. Is that the requested behavior? Because of this my 
> pool
> is running over.
> The java.sql API says that Statment.getConnection() has to be the connection
> which created the statement.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: 
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



[jira] Updated: (DBCP-11) [dbcp] stmt.getConnection() != Connection used to create the statement

2006-07-09 Thread Phil Steitz (JIRA)
 [ http://issues.apache.org/jira/browse/DBCP-11?page=all ]

Phil Steitz updated DBCP-11:


Bugzilla Id:   (was: 36077)
Fix Version: 1.2.2

> [dbcp] stmt.getConnection() != Connection used to create the statement
> --
>
>  Key: DBCP-11
>  URL: http://issues.apache.org/jira/browse/DBCP-11
>  Project: Commons Dbcp
> Type: Bug

> Versions: 1.2 Final
>  Environment: Operating System: other
> Platform: All
> Reporter: Alexander Rupsch
>  Fix For: 1.2.2

>
> Hi,
> I'm not an expert in implementing connection pools or jdbc itself. But 
> shouldn't
> the following code work?
> Connection con = pool.getConnection()
> PreparedStatement ps = con.prepareStatement()
> con.equals(ps.getConnection) // returns false!
> Ok, I don't need it to be equal, but the following also does not work:
> ps.getConnection().close()
> con.isClosed() // is false!!!
> That means, if I have a Statment and want to close its connection, I have to
> remember the conncetion. Is that the requested behavior? Because of this my 
> pool
> is running over.
> The java.sql API says that Statment.getConnection() has to be the connection
> which created the statement.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]