I do something similar and the way I do it is by configuring the logger in the
Log4J properties file. For example, make "LOGGER_1" use one file appender that
writes to "c:\log1.txt". Then use Logger.getLogger( "LOGGER_1"
).error("message") to write to that file. All other loggers can be configured
(by configuring the root logger) to an appender that writes to "c:\log2.txt".
Then any other logger other than "LOGGER_1" will append to log2.txt.
-----Original Message-----
From: Wm.A.Stafford [mailto:[EMAIL PROTECTED]
Sent: March 30, 2007 9:05 AM
To: [email protected]
Subject: Two separate log files
I would like to programatically select between two log files, is this
possible? One file is the typical log file and the other is used for
traffic analysis and will be logged to by interceptors that are
analyzing URL. Could someone point me to an example of how this is done?
Thanks,
-=bill
---------------------------------------------------------------------
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]