ibatis-user-java mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From max_lazz...@tiscali.it
Subject Re: Logging?
Date Thu, 11 Aug 2005 07:38:21 GMT
Hi Prashanth,
I've tried to remove all "unnecessary" lines from the log4j.properties file
but nothing changed.
At the moment this is my configuration:

*** LIBs in project classpath ***
- commons-logging-api.jar
- commons-logging.jar
- log4j.1.2.11.jar

*** log4j.properties file ***
# Global logging configuration
log4j.rootLogger=DEBUG, stdout, DAILY_FILE

# for ibatis
# SqlMap logging configuration...
log4j.logger.com.ibatis=DEBUG
log4j.logger.java.sql=DEBUG

# Console output
log4j.appender.stdout=org.apache.log4j.ConsoleAppender
log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
log4j.appender.stdout.layout.ConversionPattern=%p [%d] [%t] [%c{1}] [%F:%L]
- %m%n

#
# DAILY_FILE is a DailyFileAppender
#
log4j.appender.DAILY_FILE=org.apache.log4j.DailyRollingFileAppender
log4j.appender.DAILY_FILE.File=C:\\logging\\log4j.log
log4j.appender.DAILY_FILE.DatePattern='.'yyyy-MM-dd
log4j.appender.DAILY_FILE.layout=org.apache.log4j.PatternLayout
log4j.appender.DAILY_FILE.layout.ConversionPattern=%-5p %d{ISO8601}: %c.%M()
: %m%n


I've not used any "Configurator" anywhere (esplicitly), perhaps I'm using
some kind of default. 

Still having logs from "my" code but no logs from iBatis. The same configuration
worked fine on Eclipse with TomCat5 but on this IBM environment (Rational
+ WebSphere5 AS) it doesn't behave the same. 

If I find some different configuration/solution I'll let you know.

Rgrds

Max 



>-- Messaggio Originale --
>Reply-To: user-java@ibatis.apache.org
>Date: Wed, 10 Aug 2005 10:50:18 -0700 (PDT)
>From: Prashanth Sukumaran <prashanthsukumaran@yahoo.com>
>Subject: Re: Logging?
>To: user-java@ibatis.apache.org
>
>
>Hi Max,
>
>In your previous mail you mentioned that you are seeing other debug statements
>but you are not
>seeing only 
>                "log4j.logger.com.ibatis.*" and "log4j.logger.java.sql.*"
>rows 
>                 seems not to have effect on logging.
>
>This means your log4j Properties Configurator is fine.  Somebody or you
have
>already has taken
>care of that.  Configurator works fine.
>
>for the ibatis configurate in log4j.properties file  just use
>
>log4j.logger.com.ibatis=DEBUG   (It will automatically apply to all the
packages
>
>                                  within com.ibatis.)
>log4j.logger.java.sql=DEBUG 
>
>Don't do log4j.logger.com.ibatis.common.jdbc.SimpleDataSource=DEBUG,stdout,
>DAILY_FILE
>
>You don't have to specify all the stdout and DAILY_FILE.  You have done
that
>in log4j.rootLogger
>configuration.
>
>can you try that and let us know.
>
>Thanks
>Prashanth
>
>--- eOk <eok@vodafone.ie> wrote:
>
>> Max
>> 
>> You can use a servlet which is started when the webapp starts to  
>> configure the log4j Properties Configurator.  The Configurator has a 

>> configureAndWatch method that allows you start log4j but also allow  
>> it to be reloaded at runtime.
>> 
>> Set the watch level to something small so you can tweak log4j and see

>
>> the changes in the debug (set debug=true) at the top.
>> 
>> See http://www.vipan.com/htdocs/log4jhelp.html for some good Log4j  
>> stuff and http://logging.apache.org/log4j/docs/manual.html for  
>> details on the servlet.
>> 
>> regards
>> 
>> Eoin
>> 
>> Check out
>> On 10 Aug 2005, at 17:48, max_lazzari@tiscali.it wrote:
>> 
>> > Sorry for my ignorance, what is the  
>> > "log4j.PropertyConfigurator.configure",
>> > I only have the log4j.properties file located in my "WEB-INF 
>> > \classes" project
>> > directory.
>> >
>> > How\Where should I use "log4j.PropertyConfigurator.configure" ?
>> >
>> > thanks in advance
>> >
>> > Max
>> >
>> >
>> >> -- Messaggio Originale --
>> >> Reply-To: user-java@ibatis.apache.org
>> >> Subject: RE: Logging?
>> >> Date: Wed, 10 Aug 2005 17:31:18 +0100
>> >> From: "James, Steven" <Steven.James@logicacmg.com>
>> >> To: <user-java@ibatis.apache.org>
>> >>
>> >>
>> >> I use log 4j on do not have any problems with ibatis debug are you

>
>> >> seting
>> >> the log4j.PropertyConfigurator.configure  wilth your properties?
>> >>
>> >> Steve..
>> >>
>> >> ________________________________
>> >>
>> >> From: max_lazzari@tiscali.it [mailto:max_lazzari@tiscali.it]
>> >> Sent: Wed 10/08/2005 16:57
>> >> To: user-java@ibatis.apache.org; user-java@ibatis.apache.org
>> >> Subject: Re: Logging?
>> >>
>> >>
>> >>
>> >> Hi,
>> >> I had "commons-logging.jar" and "log4j-1.2.8.jar" in my project  
>> >> classPath
>> >> and didn't see logs from iBatis.
>> >> I tried to add even "commons-logging-api.jar" to the classPath but

>
>> >> nothing
>> >> changed...
>> >> I'm starting thinking it is Rational (WebSphere Studio) having  
>> >> some problems
>> >> in showing logs.
>> >>
>> >> Just for your info I can see logs that I "call" programmatically  
>> >> with "log.debug(...)"
>> >> statement.
>> >>
>> >> Still investigating for a solution to this problem.
>> >>
>> >>
>> >>
>> >>> -- Messaggio Originale --
>> >>> Reply-To: user-java@ibatis.apache.org
>> >>> Date: Wed, 10 Aug 2005 15:40:15 +0300
>> >>> From: Eugeny N Dzhurinsky <eugenydzh@jdevelop.com>
>> >>> To: user-java@ibatis.apache.org
>> >>> Subject: Re: Logging?
>> >>>
>> >>>
>> >>> On Wed, Aug 10, 2005 at 07:36:19AM -0500, Mitchell, Steven C wrote:
>> >>>
>> >>>> That is a question for IBM.  If you have a JUnit test you can  
>> >>>> run from
>> >>>>
>> >>> the
>> >>>
>> >>>> command line logging works fine and you can see all the detail 

>> >>>> you need.
>> >>>>
>> >>> It
>> >>>
>> >>>> just doesn't work from inside of RAD.  Let me know if you find 

>> >>>> the answer
>> >>>> because I have the same issue.
>> >>>>
>> >>>
>> >>> I don't think it's IBM-related issue. I've tried to use the  
>> >>> iBATIS 2.1.5
>> >>> w/o
>> >>> the commons-logging libraries in the classpath, and w/o any luck 

>> >>> (JDK
>> >>> 1.4.2_p7), but when I added the commons-logging-api.jar and
>> >>> commons-logging.jar to the classpath - I started to see the debug

>
>> >>> messages
>> >>> from the ibatis. If i remove these 2 libraries - it won't work.
>> >>>
>> >>> --
>> >>> Eugene N Dzhurinsky
>> >>>
>> >>
>> >>
>> >> __________________________________________________________________
>> >> TISCALI ADSL 1.25 MEGA
>> >> Solo con Tiscali Adsl navighi senza limiti e telefoni senza canone

>
>> >> Telecom
>> >> a partire da 19,95 Euro/mese.
>> >> Attivala entro il 31 agosto, il primo MESE è GRATIS! CLICCA QUI.
>> >> http://abbonati.tiscali.it/adsl/sa/1e25flat_tc/
>> >>
>> >>
>> >>
>> >>
>> >>
>> >>
>> >>
>> >> This e-mail and any attachment is for authorised use by the  
>> >> intended recipient(s)
>> >> only. It may contain proprietary material, confidential  
>> >> information and/or
>> >> be subject to legal privilege. It should not be copied, disclosed 

>> >> to, retained
>> >> or used by, any other party. If you are not an intended recipient 

>> >> then please
>> >> promptly delete this e-mail and any attachment and all copies and 

>> >> inform
>> >> the sender. Thank you.
>> >>
>> >> Allegato: winmail.dat
>> >>
>> >>
>> >
>> >
>> > __________________________________________________________________
>> > TISCALI ADSL 1.25 MEGA
>> > Solo con Tiscali Adsl navighi senza limiti e telefoni senza canone 

>> > Telecom
>> > a partire da 19,95 Euro/mese.
>> > Attivala entro il 31 agosto, il primo MESE è GRATIS! CLICCA QUI.
>> > http://abbonati.tiscali.it/adsl/sa/1e25flat_tc/
>> >
>> >
>> >
>> >
>> 
>> 
>
>
>
>		
>____________________________________________________
>Start your day with Yahoo! - make it your home page 
>http://www.yahoo.com/r/hs 
> 


__________________________________________________________________
TISCALI ADSL 1.25 MEGA
Solo con Tiscali Adsl navighi senza limiti e telefoni senza canone Telecom
a partire da 19,95 Euro/mese.
Attivala entro il 31 agosto, il primo MESE è GRATIS! CLICCA QUI.
http://abbonati.tiscali.it/adsl/sa/1e25flat_tc/




Mime
View raw message