logging-log4j-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Campos Rui Oliveira" <rui.cam...@enabler.com>
Subject Concurrency and performance degradation
Date Fri, 21 Nov 2003 16:34:49 GMT
Hi, everyone.

I'm stress testing a J2EE application and in certain executions (it is not happening always
for the same conditions, maybe in 10% of the cases), i have got terrible times for a test
case, and when i go and analyze where the most of the time is consumed, i realized that there
is at Log4j in Category.info() statements.

Our logging strategy is to have a static Logger variable in each class that we want to have
logging enabled with the fully qualified class name as the name of the logger. We are using
DailyRollingFileAppender and ConsoleAppender to log into a file and into the console output.

There is anyway to improve the performance in a concurrency environment (maybe defining a
buffer size and have only one thread writing to the file and to the console? ) and prevent
this concurrency problems?
If, instead of having the logger for each class as a static variable, if i have a Logger instance
for each instance of each class (as an instance variable), the performance is improved?

> Rui Campos

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

View raw message