Hi,
I have 2 web-applications, running simultaniously (under
tomcat if that matters).
1. One of the applications is directly using the log4j API (configured through file log4j.xml).
2. The other is directly using the java.util.logging API (configured thorugh file logging.properties).
My question:
can I have both applications write to the same output file, e.g. "c:/myLog.log" ?
Note I can't touch the existing applications code, especially not re-write them so as to use a common API (such as commons-logging).
I can only change the configuration files.
Basically, I could tell log4.xml to use a FileAppender to "c:/myLog.log",
and then tell logging.properties to use a similar FileHandler to "c:/myLog.log".
But I was afraid it would cause conflicts (it's 2 buffered streams writing to the same file, which is weird I think - at the very least, it would mess up the order of messages, e.g. see the beginning of a log4j message, then cut off in mid-sentence to some JUL message, then continue the log4j message...).
Thanks.
[ September 02, 2007: Message edited by: Sol Ma-Orn ]