Return-Path: Delivered-To: apmail-struts-user-archive@www.apache.org Received: (qmail 4665 invoked from network); 14 Jun 2006 13:27:50 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 14 Jun 2006 13:27:50 -0000 Received: (qmail 57566 invoked by uid 500); 14 Jun 2006 13:27:39 -0000 Delivered-To: apmail-struts-user-archive@struts.apache.org Received: (qmail 57517 invoked by uid 500); 14 Jun 2006 13:27:38 -0000 Mailing-List: contact user-help@struts.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Help: List-Post: List-Id: "Struts Users Mailing List" Reply-To: "Struts Users Mailing List" Delivered-To: mailing list user@struts.apache.org Received: (qmail 57506 invoked by uid 99); 14 Jun 2006 13:27:38 -0000 Received: from asf.osuosl.org (HELO asf.osuosl.org) (140.211.166.49) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 14 Jun 2006 06:27:38 -0700 X-ASF-Spam-Status: No, hits=0.8 required=10.0 tests=INFO_TLD,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (asf.osuosl.org: domain of dhall@utrs.com designates 146.145.175.13 as permitted sender) Received: from [146.145.175.13] (HELO mail1.utrs.com) (146.145.175.13) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 14 Jun 2006 06:27:36 -0700 Received: from Darrenh7485 [192.168.0.211] by mail1.utrs.com with ESMTP (SMTPD-9.04) id AECA049C; Wed, 14 Jun 2006 09:27:38 -0400 From: "Darren Hall" To: "'Struts Users Mailing List'" Subject: RE: log4j - urgent Date: Wed, 14 Jun 2006 09:25:47 -0400 Message-ID: <003301c68fb6$190f49d0$800101df@utrschad> MIME-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit X-Priority: 3 (Normal) X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook, Build 10.0.6626 In-Reply-To: X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2869 Importance: Normal X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N (continued from previous msg) HERE is the log4j.xml file I'm using (I forgot to include it in my last message). -----Original Message----- From: Li [mailto:ampyx.li@gmail.com] Sent: Wednesday, June 14, 2006 2:27 AM To: Struts Users Mailing List Subject: Re: log4j - urgent Hi Koul, If you wanna simply use log4j in Struts application. You can just import log4j and create a Logger instance in your source files, something like: import org.apache.log4j.Logger; .... Logger logger = Logger.getLogger(YourClassName.class); ... Then you can just use logger to log your information, something like: ... logger.debug("debug"); logger.info("info"); ... Application servers also use log4j such as Tomcat, JBoss. You can configure log4j for server log as well .... Wish it helps On 6/14/06, Abhimanyu Koul wrote: > > hi all! > i am using log4j in my application but am a bit confused about it. what r > the steps to use log4j in my application. > why do we need to create log4jservlet class in the application. > is it necessary? if no, why do we create it? > also, how does logfactory get to know that we are using log4j in the > application > thanks > > Regards, > Abhimanyu Koul > FinEng Solutions (P) Ltd. > Mobile : +91 9819510090 > > -- ===================================== The world will be ended if love is everywhere. ---- Shawzi --------------------------------------------------------------------- To unsubscribe, e-mail: user-unsubscribe@struts.apache.org For additional commands, e-mail: user-help@struts.apache.org