tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Katilie, John" <John.Kati...@softwareagusa.com>
Subject RE: Connection Pooling and Teradata
Date Wed, 18 Jun 2008 20:48:25 GMT
Thanks, for the effort. It's interesting that when I moved my log4j jar
file from my apps directory into tomcat/lib and added the log4j parm in
my apps log4j.properties file I got tons of logging messages but none
from dbcp..

log4j.logger.org.apache=ALL, DBCPCONSOLEAppender

Thanks, jfk

-----Original Message-----
From: Christopher Schultz [mailto:chris@christopherschultz.net] 
Sent: Wednesday, June 18, 2008 4:05 PM
To: Tomcat Users List
Subject: Re: Connection Pooling and Teradata

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

John,

Christopher Schultz wrote:
| I use log4j, and have it correctly configured to use log4j in my
| application, so I added:
|
| log4j.category.org.apache.tomcat.dbcp=ALL

I followed the instructions on this page
(http://tomcat.apache.org/tomcat-5.5-doc/logging.html) to set up Tomcat
to use log4j. I set the following log4j.properties:

log4j.rootLogger=INFO,R
log4j.appender.R=org.apache.log4j.FileAppender
log4j.appender.R.File=/tmp/tomcat.log
log4j.appender.R.layout=org.apache.log4j.PatternLayout
log4j.appender.R.layout.ConversionPattern=%p %t %c - %m%n

log4j.category.org.apache.tomcat.dbcp=ALL

... and got no useful output from DBCP in /tmp/tomcat.log (which was
created and did have output from other components).

A commons-user post from a few years ago seems to indicate that DBCP
does not do any logging. A cursory look at the source myself confirms
this assertion. :(

That would have been easier to check than re-configuring my Tomcat ;)

Anyhow, you could always browse the code to check for additional
statements issued by DBCP. Other than the "validation query" and
possibly a COMMIT issued when returning an autocommit=false connection
back to an autocommit=true pool (because setting autocommit=true on an
autocommit=false connection causes a COMMIT to occur), there should be
no query overhead added by DBCP.

- -chris
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iEYEARECAAYFAkhZan8ACgkQ9CaO5/Lv0PBHigCcCnlWOBhRwU6fwFeKHGeg43+2
HL8AoMGNUUoycYbmPE3T78LD89Ggl7iF
=ZhdY
-----END PGP SIGNATURE-----

---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Mime
View raw message