uima-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Peter Klügl (JIRA) <...@uima.apache.org>
Subject [jira] [Commented] (UIMA-3225) Loading scripts within jars
Date Fri, 30 Aug 2013 10:52:53 GMT

    [ https://issues.apache.org/jira/browse/UIMA-3225?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13754574#comment-13754574
] 

Peter Klügl commented on UIMA-3225:
-----------------------------------

I added a test and fixed some remaining problems. It should work now. Further refactoring
will be performed in UIMA-3226.
                
> Loading scripts within jars
> ---------------------------
>
>                 Key: UIMA-3225
>                 URL: https://issues.apache.org/jira/browse/UIMA-3225
>             Project: UIMA
>          Issue Type: Bug
>          Components: ruta
>    Affects Versions: 2.0.1ruta
>            Reporter: Peter Klügl
>            Assignee: Peter Klügl
>             Fix For: 2.0.2ruta
>
>
> Reported by Saad in UIMA-3194:
> I wanted to report a similar problem when a script use the "SCRIPT" declaration to import
anoter script, and those 2 scripts are packaged in a JAR file. additionalScripts are loaded
using the File class exclusively, not ClassLoader.getSystemResourceAsStream():
> org.apache.uima.ruta.engine.RutaEngine.loadScript(RutaEngine.java:677).
> Full stack:
> {noformat}
> org.apache.uima.resource.ResourceInitializationException: Initialization of annotator
class "org.apache.uima.ruta.engine.RutaEngine" failed.  (Descriptor: file:/Users/saadtazi/Documents/workspace/ruta-jar-test/target/ruta-jar-test-0.0.1-SNAPSHOT-jar-with-dependencies/testEngine.xml)
> 	at org.apache.uima.analysis_engine.impl.PrimitiveAnalysisEngine_impl.initializeAnalysisComponent(PrimitiveAnalysisEngine_impl.java:252)
> 	at org.apache.uima.analysis_engine.impl.PrimitiveAnalysisEngine_impl.initialize(PrimitiveAnalysisEngine_impl.java:156)
> 	at org.apache.uima.impl.AnalysisEngineFactory_impl.produceResource(AnalysisEngineFactory_impl.java:94)
> 	at org.apache.uima.impl.CompositeResourceFactory_impl.produceResource(CompositeResourceFactory_impl.java:62)
> 	at org.apache.uima.UIMAFramework.produceResource(UIMAFramework.java:269)
> 	at org.apache.uima.UIMAFramework.produceAnalysisEngine(UIMAFramework.java:387)
> 	at org.apache.uima.analysis_engine.asb.impl.ASB_impl.setup(ASB_impl.java:254)
> 	at org.apache.uima.analysis_engine.impl.AggregateAnalysisEngine_impl.initASB(AggregateAnalysisEngine_impl.java:431)
> 	at org.apache.uima.analysis_engine.impl.AggregateAnalysisEngine_impl.initializeAggregateAnalysisEngine(AggregateAnalysisEngine_impl.java:375)
> 	at org.apache.uima.analysis_engine.impl.AggregateAnalysisEngine_impl.initialize(AggregateAnalysisEngine_impl.java:185)
> 	at org.apache.uima.impl.AnalysisEngineFactory_impl.produceResource(AnalysisEngineFactory_impl.java:94)
> 	at org.apache.uima.impl.CompositeResourceFactory_impl.produceResource(CompositeResourceFactory_impl.java:62)
> 	at org.apache.uima.UIMAFramework.produceResource(UIMAFramework.java:269)
> 	at org.apache.uima.UIMAFramework.produceAnalysisEngine(UIMAFramework.java:354)
> 	at org.apache.uima.tools.docanalyzer.DocumentAnalyzer.runProcessingThread(DocumentAnalyzer.java:1167)
> 	at org.apache.uima.tools.docanalyzer.DocumentAnalyzer$ProcessingThread.run(DocumentAnalyzer.java:1267)
> Caused by: java.lang.NullPointerException
> 	at java.io.File.<init>(File.java:251)
> 	at org.apache.uima.ruta.engine.RutaEngine.loadScript(RutaEngine.java:677)
> 	at org.apache.uima.ruta.engine.RutaEngine.recursiveLoadScript(RutaEngine.java:621)
> 	at org.apache.uima.ruta.engine.RutaEngine.initializeScript(RutaEngine.java:524)
> 	at org.apache.uima.ruta.engine.RutaEngine.initialize(RutaEngine.java:254)
> 	at org.apache.uima.analysis_engine.impl.PrimitiveAnalysisEngine_impl.initializeAnalysisComponent(PrimitiveAnalysisEngine_impl.java:250)
> 	... 15 more
> {noformat}

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Mime
View raw message