[prev in list] [next in list] [prev in thread] [next in thread]
List: jakarta-commons-dev
Subject: Re: [DBCP] proposal for activationStatement and passivationStatement
From: Dirk Verbeeck <dirk.verbeeck () pandora ! be>
Date: 2003-12-21 20:36:26
[Download RAW message or body]
Yes this would be a nice feature, a couple of days ago there was
somebody else requesting a similar thing on commons-user.
A patch is very welcome.
One remark, I would stop the normal processing when an exception is
thrown. If needed you can always handle error in a PL/SQL block or
stored procedure.
-- Dirk
Brent Verner wrote:
> 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 "activationStatement" and a "passivationStatement".
> 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 activateObject() and
> passivateObject() methods (of PoolableConnectionFactory). If an
> exception is thrown when executing either, a message is logged,
> and normal processing continues, i.e., a "bad" activationStatement
> will not cause the connection to be considered "bad".
>
> If this is something that might be considered for inclusion
> in dbcp, please give me some feedback/comments on the notes
> above and I'll send a patch.
>
> cheers.
> Brent
>
---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-dev-help@jakarta.apache.org
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic