tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Filip Hanik - Dev Lists <>
Subject Re: DBCP config question
Date Fri, 28 Aug 2009 21:01:33 GMT
its better to see if there is a way to do it in the JDBC url itself.
As soon as you set the defaultAutoCommit flag to a value, DBCP will 
issue a getAutoCommit and possible setAutoCommit each time you use the 
connection. Both calls may go back to the DB depending on how the driver 
implements it.

Alternatively, you can try out a pool that is being developed in the 
tomcat community, which as a ConnectionState component that caches the 
auto commit state.
It also has a initSQL attribute to setup a DB session first time its 
connected to the DB.


On 08/28/2009 02:27 PM, Bill Davidson wrote:
> Tomcat 6.0.18
> Oracle 10g
> Java 1.6.0_14
> I'm a little curious about the defaultAutoCommit parameter.
> If I understand the docs and things I've googled correctly, if I don't
> set it, I get the JDBC driver default.  More googling, suggests that
> the default for the Oracle JDBC driver is to have auto-commit
> enabled.  I'm pretty sure I don't want that since I have some complex
> transactions going on.
> So I'm thinking I should set it to false to disable auto-commit.  Is
> that correct?
> ---------------------------------------------------------------------
> To unsubscribe, e-mail:
> For additional commands, e-mail:

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message