On 5/15/07, Katherine Enderling <[EMAIL PROTECTED]> wrote:
Hi

I am having what appears to be a classpath problem when trying to run UIMA
from an Ant task. I am running Java version 1.4.2.


So far I can't reproduce this issue.  I was able to run this ant task
in Java 1.4.2:

 <target name="run">
   <java classname="org.apache.uima.tools.docanalyzer.DocumentAnalyzer"
fork="true">
     <classpath>
       <fileset dir="c:/apache-uima-2.2/lib" includes="*.jar"/>
     </classpath>
   </java>
 </target>

(Although when I ran without fork="true" I got a NoClassDefFoundError
on an XML parser class, I'm not sure what's wrong with that.)


UIMA is definitely designed to support Java 1.4.  Usually it detects
that JMX is not available and doesn't use it.  I'm not sure what is
going on here - do you have any JMX jar files on your classpath?


java.lang.NoClassDefFoundError: com/sun/jmx/mbeanserver/GetPropertyAction
    at java.lang.Class.forName0(Native Method)
    at java.lang.Class.forName(Class.java:141)
    at
org.apache.uima.internal.util.JmxMBeanAgent.<clinit>(JmxMBeanAgent.java:154)
    at

JmxMBeanAgent:154 is:

     objectNameClass = Class.forName("javax.management.ObjectName");

And this is enclosed in a try...catch to catch a
ClassNotFoundException if this class doesn't exist, which it shouldn't
in a plain 1.4 JRE with no JMX support installed.  It looks like
javax.management.ObjectName exists in your classpath but it in turn
has a dependency on com.sun.jmx.mbeanserver.GetPropertyAction, which
is not being found.  That's what makes me ask if you have any JMX jar
files on your classpath.

-Adam

Reply via email to