Hi David,
I feel with you but it is a little bit difficult to help since I'm not
an expert but I just created log4j.properties for a project
+) the "normal" log message are going to console, file and xml
+) I need the logs from yaafi.performance and yaafi.tracing be stored in
a seperate logfiles since this is diagnostic stuff and would flood the
normal logfile. Furthermore I'm using a diferent layout since these are
CSV files
+) at the very end I supress most messaged from log4j.logger.yaafi logger
I think this is pretty much what you would need ..
Have fun and don't forget to post a success story ...
Siegfried Goeschl
#
# create three appenders
#
log4j.rootLogger=INFO, stdout, file, xml
#
# custom logfiles
#
log4j.category.yaafi.tracing = DEBUG, tracing
log4j.additivity.yaafi.tracing = false
log4j.category.yaafi.performance = DEBUG, performance
log4j.additivity.yaafi.performance = false
#
# configure the stdout appender to go to the console
#
log4j.appender.stdout=org.apache.log4j.ConsoleAppender
log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
log4j.appender.stdout.layout.ConversionPattern=%d [%t] %-5p %c %x - %m%n
#
# File Appender
#
log4j.appender.file=org.apache.log4j.RollingFileAppender
log4j.appender.file.File=./temp/it20one-signature-service.log
log4j.appender.file.MaxFileSize=1000KB
log4j.appender.file.MaxBackupIndex=2
log4j.appender.file.layout=org.apache.log4j.PatternLayout
log4j.appender.file.layout.ConversionPattern=%d [%t] %-5p %c %x - %m%n
#
# XML Layout
#
log4j.appender.xml=org.apache.log4j.FileAppender
log4j.appender.xml.file=./temp/it20one-signature-service.log.xml
log4j.appender.xml.layout=org.apache.log4j.xml.XMLLayout
log4j.appender.xml.append=false
#
# Tracing Appender
#
log4j.appender.tracing = org.apache.log4j.RollingFileAppender
log4j.appender.tracing.file = ./temp/tracing.csv
log4j.appender.tracing.MaxFileSize=2000KB
log4j.appender.tracing.layout=org.apache.log4j.PatternLayout
log4j.appender.tracing.layout.conversionPattern=%d;%t;%m%n
log4j.appender.tracing.threshold=DEBUG
log4j.appender.tracing.append = true
#
# Performance Appender
#
log4j.appender.performance = org.apache.log4j.RollingFileAppender
log4j.appender.performance.file = ./temp/performance.csv
log4j.appender.performance.MaxFileSize=2000KB
log4j.appender.performance.layout = org.apache.log4j.PatternLayout
log4j.appender.performance.layout.conversionPattern = %d;%t;%m%n
log4j.appender.performance.threshold=DEBUG
log4j.appender.performance.append = true
#
# Additional settings for supressing unwanted logging
#
log4j.logger.yaafi=WARN
David Thielen wrote:
Hi;
We're stuck on our logging properties (and I'm getting beat on a lot). And
everything I have tried has not worked. Rather than show what I have tried,
I figure it is easier to just list what we need.
* This is on Tomcat so it must be a text (not xml) properties file. There is
a bug in Tomcat that has problems with the xml file.
* Three output destinations - console, tomcat.log, and windward.log.
* Console - error on server. On dev boxes also need info for
org.apache.catalina
* tomcat.log - warn. If possible, nothing from net.windward
* windward.log - info from net.windward
This is driving me nuts because it is pretty simple and there has to be a
simple way to do it. But everything I have tried has failed. If anyone could
help, I would really appreciate it.
Thanks - dave
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]