Hi all,
I am working on vindico, a replacement for Alexandria over in the
Alexandria CVS, and I am using commons-digester, which in turn uses
commons-logging.
When running Vindico as an Ant task, it starts running and then says
that it cannot find the LogFactoryImpl class.
I have traced this down to the getClassLoader() function in LogFactory,
which returns the Thread.getContextClassLoader() if there is one.
The problem that I have is the LogFactoryImpl class is in the same class
loader as LogFactory, so I am suggesting a change to LogFactory, such
that the default class loader is used. Patch is below. Are there other
problems that this does not address?
Any questions, comments, suggestions?
If not, I will commit this.
Scott
Index: src/java/org/apache/commons/logging/LogFactory.java
===================================================================
RCS file:
/home/cvs/jakarta-commons/logging/src/java/org/apache/commons/logging/Lo
gFactory.java,v
retrieving revision 1.6
diff -u -r1.6 LogFactory.java
--- src/java/org/apache/commons/logging/LogFactory.java 15 Mar 2002
22:57:36 -0000 1.6
+++ src/java/org/apache/commons/logging/LogFactory.java 22 Apr 2002
16:48:12 -0000
@@ -347,7 +347,7 @@
// Fourth, try the fallback implementation class
if (factory == null) {
- factory = newFactory(FACTORY_DEFAULT, classLoader);
+ factory = newFactory(FACTORY_DEFAULT,
LogFactory.class.getClassLoader());
}
if( props!=null ) {
--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>