commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Todd V. Jonker" <T...@ConsciousCode.com>
Subject Re: Where is the fix for "org.apache.commons.logging.impl.Log4JCategoryLog does not implement Log" ?
Date Tue, 04 Nov 2003 21:25:58 GMT
Madhav,

You have another copy of commons-logging.jar in the classpath being used
by the ant task.  Probably in your ant/lib directory.  In that case you
probably shouldn't have it in the system CLASSPATH.

I suggest setting up your build environment so that your system CLASSPATH
can be empty.  This helps one avoid these kinds of problems.

Hope this helps,

.T.

On Tue, 4 Nov 2003 14:54:29 -0600, "Ayyagari, Madhav"
<Madhav.Ayyagari@sabre.com> said:
> Hi All,
> 
> I tried using both commons-logging.jar 1.0.2 and 1.0.3 versions without
> any success for the following problem:
> 
> [jdoc] java.lang.ExceptionInInitializerError
> [jdoc]     at java.lang.Class.forName0(Native Method)
> [jdoc]     at java.lang.Class.forName(Class.java:217)
> [jdoc]     at
> com.solarmetric.kodo.util.MultiLoaderClassResolver.resolveClass(MultiLoaderClassResolver.java:84)
> [jdoc]     at
> com.solarmetric.modules.tools.compiler.ClassArgParser.parseClasses(ClassArgParser.java:67)
> [jdoc]     at
> com.solarmetric.kodo.enhance.JDOEnhancer.enhance(JDOEnhancer.java:175)
> [jdoc]     at
> com.solarmetric.kodo.enhance.JDOEnhancer.enhance(JDOEnhancer.java:135)
> [jdoc]     at
> com.solarmetric.modules.integration.ant.JDOEnhancerTask.executeOn(JDOEnhancerTask.java:43)
> [jdoc]     at
> com.solarmetric.modules.integration.ant.TaskBase.execute(TaskBase.java:118)
> [jdoc]     at
> org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:166)
> [jdoc]     at org.apache.tools.ant.Task.perform(Task.java:319)
> [jdoc]     at org.apache.tools.ant.Target.execute(Target.java:309)
> [jdoc]     at org.apache.tools.ant.Target.performTasks(Target.java:336)
> [jdoc]     at
> org.apache.tools.ant.Project.executeTarget(Project.java:1306)
> [jdoc]     at org.apache.tools.ant.taskdefs.Ant.execute(Ant.java:371)
> [jdoc]     at
> org.apache.tools.ant.taskdefs.CallTarget.execute(CallTarget.java:143)
> [jdoc]     at org.apache.tools.ant.Task.perform(Task.java:319)
> [jdoc]     at org.apache.tools.ant.Target.execute(Target.java:309)
> [jdoc]     at org.apache.tools.ant.Target.performTasks(Target.java:336)
> [jdoc]     at
> org.apache.tools.ant.Project.executeTarget(Project.java:1306)
> [jdoc]     at org.apache.tools.ant.taskdefs.Ant.execute(Ant.java:371)
> [jdoc]     at org.apache.tools.ant.Task.perform(Task.java:319)
> [jdoc]     at org.apache.tools.ant.Target.execute(Target.java:309)
> [jdoc]     at org.apache.tools.ant.Target.performTasks(Target.java:336)
> [jdoc]     at
> org.apache.tools.ant.Project.executeTarget(Project.java:1306)
> [jdoc]     at org.apache.tools.ant.taskdefs.Ant.execute(Ant.java:371)
> [jdoc]     at org.apache.tools.ant.Task.perform(Task.java:319)
> [jdoc]     at org.apache.tools.ant.Target.execute(Target.java:309)
> [jdoc]     at org.apache.tools.ant.Target.performTasks(Target.java:336)
> [jdoc]     at
> org.apache.tools.ant.Project.executeTarget(Project.java:1306)
> [jdoc]     at org.apache.tools.ant.taskdefs.Ant.execute(Ant.java:371)
> [jdoc]     at org.apache.tools.ant.Task.perform(Task.java:319)
> [jdoc]     at org.apache.tools.ant.Target.execute(Target.java:309)
> [jdoc]     at org.apache.tools.ant.Target.performTasks(Target.java:336)
> [jdoc]     at
> org.apache.tools.ant.Project.executeTarget(Project.java:1306)
> [jdoc]     at
> org.apache.tools.ant.Project.executeTargets(Project.java:1250)
> [jdoc]     at org.apache.tools.ant.Main.runBuild(Main.java:610)
> [jdoc]     at org.apache.tools.ant.Main.start(Main.java:196)
> [jdoc]     at org.apache.tools.ant.Main.main(Main.java:235)
> [jdoc]     org.apache.commons.logging.LogConfigurationException:
> org.apache.commons.logging.LogConfigurationException:
> org.apache.commons.logging.LogConfigurationException: Class
> org.apache.commons.logging.impl.Log4JCategoryLog does not implement Log
> [jdoc]     at
> org.apache.commons.logging.impl.LogFactoryImpl.newInstance(LogFactoryImpl.java:555)
> [jdoc]     at
> org.apache.commons.logging.impl.LogFactoryImpl.getInstance(LogFactoryImpl.java:289)
> [jdoc]     at
> org.apache.commons.logging.impl.LogFactoryImpl.getInstance(LogFactoryImpl.java:259)
> [jdoc]     at
> org.apache.commons.logging.LogFactory.getLog(LogFactory.java:390)
> 
> The class on which the failure happening has code something like this:
> 
> import org.apache.commons.logging.Log;
> import org.apache.commons.logging.LogFactory;
> 
> public class MyClass
> {
>    private final static Log log = LogFactory.getLog(MyClass.class);
> }
> 
> Ofcourse the CLASSPATH environmental variable on solaris unix has both
> log4j.jar and commons-logging.jar in it.
> 
> I searched internet but couldnt find any conclusive fix for this. As
> suggested online it looks like a class loader problem. 
> 
> Any help is greatly appreciated.
> 
> Madhav:~
> 
> ---------------------------------------------------------------------
> 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


Mime
View raw message