Is there a way to control this? Suppose I do want to put log4j.jar in common/lib (because I don't want to wrap it in the war and reinstall it every time). But I want it only to be used by my application. Can I do this? - Dan
> There's a library called common-lib that uses any of log systems you have. > Modjk2 uses it, so if you put log4j in common/lib modjk2 will use it. If you > put modjk2 it in your webbapps directory, then only your application can > reach it. > > Regards > > -----Mensaje original----- > De: Maxime Colas des Francs [mailto:[EMAIL PROTECTED]] > Enviado el: miércoles, 02 de octubre de 2002 14:52 > Para: Tomcat Users List > Asunto: log4j & tomcat > > Hi, > > I want to use log4j in a tomcat 4.1.10 web application. > and I think I don't understand relation between tomcat and log4j. > > I have a log4j-1.2.6.jar > > If i don't put it anywhere i have a : > java.lang.NoClassDefFoundError: org/apache/log4j/PropertyConfigurator > in my 'onload' servlet (so i think it's nomal and i think log4j is not > integrate in tomcat) > > If i put this jar in $CATALINA_HOME/common/lib, > it seems that tomcat and mod_jk2 libs use it and log in my application log > ?!? > (and not a little ...) > DEBUG 2002-10-02 08:40:00,326 [main] > org.apache.jk.server.JkMain.processProperty(JkMain.java:468) : Processing > handler::handler list > DEBUG 2002-10-02 08:40:00,359 [main] > org.apache.jk.server.JkMain.processProperty(JkMain.java:468) : Processing > apr::apr NativeSo > DEBUG 2002-10-02 08:40:00,367 [main] > org.apache.jk.server.JkMain.processProperty(JkMain.java:481) : Setting > NativeSo on apr org.apache.jk.apr.AprImpl@26dbec > DEBUG 2002-10-02 08:40:00,371 [main] > org.apache.jk.server.JkMain.setBeanProperty(JkMain.java:359) : setProperty > org.apache.jk.apr.AprImpl@26dbec > ... etc ... > > If i put it in $CATALINA_HOME/webapps/myapp/WEB-INF/lib, > only my application log in my log file as expected. > > Do you know why ?? > Can i put it in common/lib and tell tomcat to stop log in my application log > ? > > Thanks. > > My log configuration : > > log4j.rootCategory=DEBUG, textFile > log4j.appender.textFile=org.apache.log4j.DailyRollingFileAppender > log4j.appender.textFile.layout=org.apache.log4j.PatternLayout > log4j.appender.textFile.layout.ConversionPattern=%-5p %d [%t] %l : %m%n > log4j.appender.textFile.DatePattern='.'yyyy-MM-dd > log4j.appender.textFile.File=/usr/local/tomcat/webapps/myapp/logs/log.txt -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>