struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Davide Bruzzone" <>
Subject RE: log4j setup
Date Wed, 24 Sep 2003 13:40:50 GMT
Here are the steps:

- Make sure that the appropriate Log4J JAR file is in your /WEB-INF/lib
- Put your file in /WEB-INF/classes
- Wherever you want to log, add the following code:

import org.apache.log4j.Logger;


// This is a private static attribute within the class
private static Logger logger = Logger.getLogger(<The name of the


// When you want to log something...

Hope this helps... If you need more information about the file, etc., the Log4J site points to lots of great (and
very detailed) documentation that you can use as a starting point...


Dave Bruzzone

-----Original Message-----
From: Viral_Thakkar [] 
Sent: Wednesday, September 24, 2003 7:23 AM
To: Struts Users Mailing List
Subject: log4j setup

Please let me know what are the steps one need to do to configure the

To unsubscribe, e-mail:
For additional commands, e-mail:

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message