uima-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Marshall Schor <...@schor.com>
Subject Re: Problem with PEAR classpath
Date Mon, 09 Jun 2008 15:04:32 GMT
Hi Aaron -

When running Pears contained in an aggregate, the Java classpath used to 
load the JCas (and other) classes is switched to be what the Pear specifies.

The classpath used by the PEAR is built using the jars in the "lib" 
directory, plus any additional paths that are specified in the PEAR 
installation descriptor's "set_env_variable" action, done by specifying 
the "CLASSPATH" environmental variable.  (see 
and scroll down to the section )

Can you verify that the JCas cover classes are either in a Jar file that 
is in the Pear's lib directory, or that you have added a environment 
variable setting action for the Pear specifying the CLASSPATH 
environmental variable and having it point to where the JCas classes are 
in the Pear structure?

Thanks. -Marshall

Aaron Kaplan wrote:
> I have two annotators that share a type system.  Each is packaged in a 
> separate pear with its own copy of the type system descriptor and the 
> associated JCas classes.  When I build an aggregate annotator using 
> the two pear descriptors and run it in the CVD, I get a run-time 
> exception in the process() method of the second annotator saying that 
> it can't find one of the cover classes.  I have verified that the 
> .class file for this class is present in the bin/ subdirectory of the 
> annotator's pear installation directory, so it seems like the 
> classpath must not be getting set properly.
> The following works fine: load the first annotator's pear descriptor 
> in the CVD, run the annotator on an input text file, save the result 
> in an XMI CAS file; load the second annotator's pear descriptor in the 
> CVD, load the XMI CAS file, run the annotator on that.  It's when I 
> combine the two annotators into an aggregate and try to run it in one 
> go that I have a problem.
> Does it sound like I'm doing something wrong?  How can I debug this?
> Thanks
> -Aaron

View raw message