Mazza, Glen R., ,CPMS wrote:
Hello,
I am thinking of using the JDK 1.4 Logging API directly within some of my
web application classes. Of course, Struts uses commons-logging for its
"internal" messages, so I still need to configure commons-logging to use the
JDK 1.4 Logging.
Yes - so why not just use commons-logging everywhere? It makes you
independent of any given logging implementation. Then, if you later
decide you need a syslog logger (oops! I don't think Java provides for
this!) or an SMTP logger (oops! again!) - can you say daily rolling
file appender? - you can just go right over to Log4J, change a couple of
properties, and voila. The fact of the matter is that there is some
existing functionality in the Log4J logger implementations that the JDK
does not have. Rather than paint yourself in a corner, why not just use
commons-logging everywhere and be independent of your logging
implementation?
I am interested in using the same output logging file for both types of
messages: those I explicitly call via JDK 1.4 Logging, and those messages
written by Struts via commons-logging. Can I have them append to the *same*
output log file without concern for them overwriting each other's messages?
I don't see how both objects could have write-access to the same file at
the same time - I would think this would be problematic. I'm not sure
how the logs are implemented, but I would think they would keep the file
open to speed logging.
Thanks,
Glen
--
Eddie Bush
--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>