Bonjour

j'essaye d'utiliser common-logging en utilisant log4j

seulement ca ne marche pas!!

mon log4j.properties qui se trouve a la base de ma webapps (WEBINF/classe)

Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
# Set root category priority to INFO and its only appender to R
log4j.fr.monpackage.maclasse.filtre=INFO, R
 
log4j.appender.R=org.apache.log4j.RollingFileAppender
log4j.appender.R.File = C:\\Tomcat 5.0\\logs\\filtreTime.log
log4j.appender.R.MaxFileSize = 500KB
log4j.appender.R.MaxBackupIndex=20
log4j.appender.R.layout=org.apache.log4j.PatternLayout
log4j.appender.R.layout.ConversionPattern=%d{DATE} [%-10t] %-5p %c{1} - %m%n
et il ne prend pas en compte mon fichier de configuration car il ecrit dans la console!!!


sinon j'ai essayer avec un commons-logging.properties


Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
org.apache.commons.logging.LogFactory=org.apache.commons.logging.impl.LogFactoryImpl   
org.apache.commons.logging.Log =org.apache.commons.logging.impl.Log4JLogger
log4j.configuration=log4j.properties
mais j'obtiens l'erreur suivante
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
 
org.apache.commons.logging.LogConfigurationException: java.lang.ClassNotFound
eption: org.apache.commons.logging.impl.LogFactoryImpl    (Caused by java.lan
lassNotFoundException: org.apache.commons.logging.impl.LogFactoryImpl   )
        at org.apache.commons.logging.LogFactory$2.run(LogFactory.java:579)
merci