Skip to Main Content

Java SE (Java Platform, Standard Edition)

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

commons-logging.jar/NullPointerException

843802Jul 31 2002 — edited Sep 4 2003
Hi,
I have an client application that uses Apache Axis, which in turn uses Apache's commons-logging.jar. The client works fine from the command line, but dies in Web Start with a NullPointerException thrown from commons-logging's LogFactory, presumably because it's unable to initialize something needed to set up logging resources (I'm not sure why the client needs logging, but apparently Axis thinks I do and it doesn't seem to be optional...). My application jar and the commons-logging jar are both signed for all-permissions, and I've included everything in the jnlp file that I use in the application classpath on the command line. I'm fairly new to Web Start and don't really have a great handle on the class loading issues, which I suspect may be involved here. I would very much appreciate hearing from anyone who has either successfully deployed an Axis application, worked through the problem, or can otherwise shed some light on what I'm missing. I've been scouring list archives on this, and haven't come up with any potential solutions other than stripping the log stuff out of the Axis client, which really isn't an option...

Error output and jnlp file are below. Thanks very much!


<?xml version="1.0" encoding="utf-8"?>
<jnlp spec="1.0+" codebase="http://localhost/offline" href="offline.jnlp">
<information>
<title>Application</title>
<homepage href="offline/"/>
<description>Application Description</description>
<offline-allowed/>
</information>
<security>
<all-permissions/>
</security>
<resources>
<j2se version="1.3" />
<jar href="offline.jar" />
<extension href="thirdparty.jnlp" />
<jar href="commons-logging.jar" />
</resources>
<application-desc main-class="Launch"/>
</jnlp>


Caused by: org.apache.commons.logging.LogConfigurationException: org.apache.commons.logging.LogConfigurationException: java.lang.NullPointerException

at org.apache.commons.logging.impl.LogFactoryImpl.newInstance(LogFactoryImpl.java:509)

at org.apache.commons.logging.impl.LogFactoryImpl.getInstance(LogFactoryImpl.java:285)

at org.apache.commons.logging.LogFactory.getLog(LogFactory.java:400)

at org.apache.axis.configuration.DefaultEngineConfigurationFactory.<clinit>(DefaultEngineConfigurationFactory.java:85)

... 15 more
Caused by: org.apache.commons.logging.LogConfigurationException: java.lang.NullPointerException
at org.apache.commons.logging.impl.LogFactoryImpl.getLogConstructor(LogFactoryImpl.java:404)
at org.apache.commons.logging.impl.LogFactoryImpl.newInstance(LogFactoryImpl.java:502)
... 18 more
Caused by: java.lang.NullPointerException
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:258)
at java.lang.ClassLoader.loadClass(ClassLoader.java:299)
at java.lang.ClassLoader.loadClass(ClassLoader.java:262)
at org.apache.commons.logging.impl.LogFactoryImpl.loadClass(LogFactoryImpl.java:434)
at org.apache.commons.logging.impl.LogFactoryImpl.getLogConstructor(LogFactoryImpl.java:398)
... 19 more


Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Oct 2 2003
Added on Jul 31 2002
8 comments
1,007 views