commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 25696] New: - initializationStatement and destructionStatement in PoolableConnectionFactory
Date Mon, 22 Dec 2003 13:32:26 GMT
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=25696>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=25696

initializationStatement and destructionStatement in PoolableConnectionFactory

           Summary: initializationStatement and destructionStatement in
                    PoolableConnectionFactory
           Product: Commons
           Version: 1.1 Final
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: Enhancement
          Priority: Other
         Component: Dbcp
        AssignedTo: commons-dev@jakarta.apache.org
        ReportedBy: dirk.verbeeck@pandora.be


proposal & patch from Brent Verner (slightly edited)
-----------------------------------------------------
  I've often had the need to perform some setup of a connection
before it can be used, such as:

  ALTER SESSION SET current_schema = workable_schema;

  As such, I've had a hacked version of dbcp around for a while
that adds an initializationStatement and destructionStatement.
Both are fed thru the Statement.execute(String) method, and 
nothing is done with any (possible) ResultSet from the query.
These statements are executed in the makeObject() and destroyObject() methods of
PoolableConnectionFactory.

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


Mime
View raw message