Return-Path: Mailing-List: contact commons-user-help@jakarta.apache.org; run by ezmlm Delivered-To: mailing list commons-user@jakarta.apache.org Received: (qmail 77465 invoked from network); 2 Sep 2003 16:29:14 -0000 Received: from unknown (HELO jemoserver) (62.3.127.84) by daedalus.apache.org with SMTP; 2 Sep 2003 16:29:14 -0000 Received: from jemoserver ([192.168.2.3]) by jemoserver (JAMES SMTP Server 2.2.0a10) with SMTP ID 770; Tue, 2 Sep 2003 17:29:15 +0100 (BST) Message-ID: <001c01c3716f$59919ed0$0302a8c0@jemoserver> From: "Marco Tedone" To: "Jakarta Commons Users List" , References: <01f601c370b4$b8354970$0302a8c0@jemoserver> <1062457275.373.6.camel@terrordome> Subject: Re: Fw: Problem switching to Struts 1.1 Date: Tue, 2 Sep 2003 17:29:15 +0100 MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 6.00.2800.1158 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165 X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N Thank you. I solved the problem by editing the commong-logging.properties file. Marco ----- Original Message ----- From: "__matthewHawthorne" To: "Jakarta Commons Users List" Sent: Tuesday, September 02, 2003 12:01 AM Subject: Re: Fw: Problem switching to Struts 1.1 > I've had similar problems lately deploying on Weblogic. While I can't > give you a 100% full-proof solution, I can tell you what I know. > > org.apache.commons.logging.impl.Log4jCategoryLog is a class for older > versions of Log4j (back when logger was category and level was priority, > I believe). > > I believe your problem has to do with code compiled with commons-logging > v1.0.2 but running with v1.0.3. I've never used Struts, so I don't know > if it has any specific peculiarities with regards to classloading vs. > the way that Tomcat behaves. > > There are some class conflicts, so you need to investigate where the > classes are being loaded from. Search all of the lib directories in > struts and tomcat and see what versions you find of commons-logging and > log4j. > > > > > On Mon, 2003-09-01 at 11:13, Marco Tedone wrote: > > Hi, as I explained in the forwarded email I switched to Struts 1.1 and my > > application can't get deployed any more. I receive the following exception: > > > > javax.servlet.ServletException: Error instantiating servlet class > > org.apache.struts.action.ActionServlet > > at > > org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:91 > > 2) > > at org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:823) > > at > > org.apache.catalina.core.StandardContext.loadOnStartup(StandardContext.java: > > 3421) > > at > > org.apache.catalina.core.StandardContext.start(StandardContext.java:3609) > > at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1188) > > at org.apache.catalina.core.StandardHost.start(StandardHost.java:738) > > at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1188) > > at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:347) > > at org.apache.catalina.core.StandardService.start(StandardService.java:497) > > at org.apache.catalina.core.StandardServer.start(StandardServer.java:2190) > > at > > org.apache.catalina.startup.CatalinaService.start(CatalinaService.java:273) > > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > > at > > sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39 > > ) > > at > > sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl > > ..java:25) > > at java.lang.reflect.Method.invoke(Method.java:324) > > at > > org.apache.catalina.startup.BootstrapService.start(BootstrapService.java:245 > > ) > > at > > org.apache.catalina.startup.BootstrapService.main(BootstrapService.java:307) > > ----- Root Cause ----- > > java.lang.ExceptionInInitializerError > > at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) > > at > > sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAcces > > sorImpl.java:39) > > at > > sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstruc > > torAccessorImpl.java:27) > > at java.lang.reflect.Constructor.newInstance(Constructor.java:274) > > at java.lang.Class.newInstance0(Class.java:308) > > at java.lang.Class.newInstance(Class.java:261) > > at > > org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:90 > > 3) > > at org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:823) > > at > > org.apache.catalina.core.StandardContext.loadOnStartup(StandardContext.java: > > 3421) > > at > > org.apache.catalina.core.StandardContext.start(StandardContext.java:3609) > > at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1188) > > at org.apache.catalina.core.StandardHost.start(StandardHost.java:738) > > at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1188) > > at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:347) > > at org.apache.catalina.core.StandardService.start(StandardService.java:497) > > at org.apache.catalina.core.StandardServer.start(StandardServer.java:2190) > > at > > org.apache.catalina.startup.CatalinaService.start(CatalinaService.java:273) > > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > > at > > sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39 > > ) > > at > > sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl > > ..java:25) > > at java.lang.reflect.Method.invoke(Method.java:324) > > at > > org.apache.catalina.startup.BootstrapService.start(BootstrapService.java:245 > > ) > > at > > org.apache.catalina.startup.BootstrapService.main(BootstrapService.java:307) > > Caused by: org.apache.commons.logging.LogConfigurationException: > > org.apache.commons.logging.LogConfigurationException: > > java.lang.ClassNotFoundException: > > org.apache.commons.logging.impl.Log4jCategoryLog > > at > > org.apache.commons.logging.impl.LogFactoryImpl.newInstance(LogFactoryImpl.ja > > va:532) > > at > > org.apache.commons.logging.impl.LogFactoryImpl.getInstance(LogFactoryImpl.ja > > va:272) > > at > > org.apache.commons.logging.impl.LogFactoryImpl.getInstance(LogFactoryImpl.ja > > va:246) > > at org.apache.commons.logging.LogFactory.getLog(LogFactory.java:395) > > at org.apache.struts.action.ActionServlet.(ActionServlet.java:375) > > ... 23 more > > Caused by: org.apache.commons.logging.LogConfigurationException: > > java.lang.ClassNotFoundException: > > org.apache.commons.logging.impl.Log4jCategoryLog > > at > > org.apache.commons.logging.impl.LogFactoryImpl.getLogConstructor(LogFactoryI > > mpl.java:416) > > at > > org.apache.commons.logging.impl.LogFactoryImpl.newInstance(LogFactoryImpl.ja > > va:525) > > ... 27 more > > Caused by: java.lang.ClassNotFoundException: > > org.apache.commons.logging.impl.Log4jCategoryLog > > at > > org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.jav > > a:1444) > > at > > org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.jav > > a:1289) > > at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:302) > > at java.lang.Class.forName0(Native Method) > > at java.lang.Class.forName(Class.java:141) > > at > > org.apache.commons.logging.impl.LogFactoryImpl$1.run(LogFactoryImpl.java:466 > > ) > > at java.security.AccessController.doPrivileged(Native Method) > > at > > org.apache.commons.logging.impl.LogFactoryImpl.loadClass(LogFactoryImpl.java > > :454) > > at > > org.apache.commons.logging.impl.LogFactoryImpl.getLogConstructor(LogFactoryI > > mpl.java:406) > > ... 28 more > > > > It seems clear that the problem is > > org.apache.commons.logging.impl.Log4jCategoryLog class which is not found. I > > had a look at the commons-logging file (I'm using version 1.0.3) and there > > is a similar class called org.apache.commons.logging.impl.Log4JCategoryLog > > (Please note the capital 'J'). How could I solve this problem? > > > > Regards, > > > > Marco > > > > > > ----- Original Message ----- > > From: "Remy Maucherat" > > To: "Tomcat Users List" > > Sent: Monday, September 01, 2003 6:37 PM > > Subject: Re: Problem switching to Struts 1.1 > > > > > > > Marco Tedone wrote: > > > > Hi, I posted this issue to the struts-user list 3 times, but noone > > replied > > > > to me and frankly I'm beginning to be a little worried. In few words we > > have > > > > an application which was running fine until struts rc1 but when we > > switched > > > > to Struts 1.1 the following exceptions is thrown: > > > > > > > > > > > > > > > The problem seems to be the > > org.apache.commons.logging.impl.Log4jCategoryLog > > > > class which is not found in the classpath. Now, I had a look at the > > > > commons-logging file and actually there is a similar class called > > > > org.apache.commons.logging.impl.Log4JCategoryLog (please note the > > capital > > > > 'J'). What shall I do then? > > > > > > Yes, something looks very fishy regarding case sensitivity with the > > > log4j support in commons-logging. You might want to file a bug against > > > commons-logging and because class naming is inconsistent, and can cause > > > user errors (for example, there's a o.a.c.l.impl.Log4jFactory class > > > along with a o.a.c.l.impl.Log4JLogger class). > > > > > > That being said, I've only seen that error occur if the webapp is > > > privileged (ie, there's a Context element with a privileged="true" > > > attribute). If you don't know what privileged does, and put it there > > > because it sounds better, I suggest you remove it (and read the docs) :) > > > > > > Remy > > > > > > > > > --------------------------------------------------------------------- > > > To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org > > > For additional commands, e-mail: tomcat-user-help@jakarta.apache.org > > > > > > > > > > > > > --------------------------------------------------------------------- > > To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org > > For additional commands, e-mail: commons-user-help@jakarta.apache.org > > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org > For additional commands, e-mail: commons-user-help@jakarta.apache.org > >