Hello every one,
I need to log messages using either tomcat logger or log4j. I have added
<Logger className="org.apache.catalina.logger.FileLogger" verbosity="1" 
prefix="localhost_gnomon_log." suffix=".txt" timestamp="true"/> under the <Context> 
tag and System.out.println("msg"); works and prints in the above named file, but i 
want to use 
the methods of org.apache.catalina.logger.FileLogger or log4j's Logger class so that i 
can turn logging on and off and can use various levels like debug,info,warn,errors 
etc. I tried to import org.apache.catalina.logger.FileLogger in java servlet, but it 
says class not found. I do have commons-logging under <server-root>/common/lib folder. 
Please guide me where am i going wrong? also if anyone who has log4j under tomcat, i 
would appreciate their guidance in setting log4j. i did create a example.cf file which 
created configuration information for log4j and placed it under WEB-INF/classes 
folder, but log4j does not picks the configuration. Any ideas would be welcomed.
Thanks
 


---------------------------------
Do you Yahoo!?
SBC Yahoo! DSL - Now only $29.95 per month!

Reply via email to