Return-Path: Delivered-To: apmail-incubator-uima-user-archive@minotaur.apache.org Received: (qmail 49515 invoked from network); 31 Mar 2009 14:52:26 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 31 Mar 2009 14:52:26 -0000 Received: (qmail 29275 invoked by uid 500); 31 Mar 2009 14:52:25 -0000 Delivered-To: apmail-incubator-uima-user-archive@incubator.apache.org Received: (qmail 29225 invoked by uid 500); 31 Mar 2009 14:52:25 -0000 Mailing-List: contact uima-user-help@incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: uima-user@incubator.apache.org Delivered-To: mailing list uima-user@incubator.apache.org Received: (qmail 29215 invoked by uid 99); 31 Mar 2009 14:52:25 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 31 Mar 2009 14:52:25 +0000 X-ASF-Spam-Status: No, hits=2.2 required=10.0 tests=HTML_MESSAGE,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of b_gaillard@hotmail.com designates 65.55.34.149 as permitted sender) Received: from [65.55.34.149] (HELO col0-omc3-s11.col0.hotmail.com) (65.55.34.149) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 31 Mar 2009 14:52:16 +0000 Received: from COL112-W17 ([65.55.34.137]) by col0-omc3-s11.col0.hotmail.com with Microsoft SMTPSVC(6.0.3790.3959); Tue, 31 Mar 2009 07:51:55 -0700 Message-ID: Content-Type: multipart/alternative; boundary="_ed886b82-f642-45b8-8029-65c05b3ef6e0_" X-Originating-IP: [192.54.144.229] From: Baptiste Gaillard To: Subject: Instatiate an aggregate AE having reference to a UriSpecifier Date: Tue, 31 Mar 2009 14:51:55 +0000 Importance: Normal MIME-Version: 1.0 X-OriginalArrivalTime: 31 Mar 2009 14:51:55.0288 (UTC) FILETIME=[3C03E980:01C9B210] X-Virus-Checked: Checked by ClamAV on apache.org --_ed886b82-f642-45b8-8029-65c05b3ef6e0_ Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Hi=2C=20 On our project we are currently trying to create OSGI Bundle to integrate U= IMA components.=20 For the moment it works well but I have an instantiation problem using an a= ggregate AE which reference a Vinci descriptor.=20 He is what i'm doing:=20 -- Main descriptor of the aggregate AE (X.xml) -- org.apache.uima.java false =20 =20 XXX slmkjhsqldkjfhldfjkh 1.0 XXX =20 B A true true false -- Descriptor B.xml describes a UriSpecifier -- AnalysisEngine XXX Vinci Then in Java i'm using this code to instantiate the Aggregate AE (uimaCompo= nentDescriptorPath is the path to the main component descriptor=2C uima) : ConfigurationManager configurationManager =3D UIMAFramework.newConf= igurationManager()=3B try { // uimaComponentDescriptorPath is the path to the main componen= t descriptor of the aggregate (X.xml) ResourceSpecifier uimaComponentDescription =3D UIMAFramework.ge= tXMLParser().parseResourceSpecifier(new File(uimaComponentDescriptorPath))= =3B // uimaComponentRootPath is the path to the root directory of t= he aggregate AE ResourceManager resourceManager =3D UIMAFramework.newDefaultRes= ourceManager()=3B resourceManager.setDataPath(uimaComponentRootPath)=3B // Component classPath is computed using an utility function String uimaComponentClassPath =3D this.buildUimaComponentClassP= ath(uimaComponentRootPath)=3B resourceManager.setExtensionClassPath(this.getClass().getClassL= oader()=2C uimaComponentClassPath=2C true)=3B =20 AnalysisEngine analysisEngine =3D UIMAFramework.produceAnalysis= Engine(this.uimaComponentDescription=2C resourceManager=2C null)=3B } catch (Exception e) { } The line AnalysisEngine analysisEngine =3D UIMAFramework.produceAnalysisEng= ine(this.uimaComponentDescription=2C resourceManager=2C null)=3B throws an = exception :=20 org.apache.uima.resource.ResourceInitializationException: The Resource Fact= ory does not know how to create a resource of class org.apache.uima.analysi= s_engine.AnalysisEngine from the given ResourceSpecifier. (Descriptor: file= :/D:/workspace_npf/component/desc/B.xml) at org.apache.uima.UIMAFramework.produceResource(UIMAFramework.java:261= ) at org.apache.uima.UIMAFramework.produceAnalysisEngine(UIMAFramework.ja= va:352) at org.apache.uima.analysis_engine.asb.impl.ASB_impl.setup(ASB_impl.jav= a:243) at org.apache.uima.analysis_engine.impl.AggregateAnalysisEngine_impl.in= itASB(AggregateAnalysisEngine_impl.java:413) at org.apache.uima.analysis_engine.impl.AggregateAnalysisEngine_impl.in= itializeAggregateAnalysisEngine(AggregateAnalysisEngine_impl.java:361) at org.apache.uima.analysis_engine.impl.AggregateAnalysisEngine_impl.in= itialize(AggregateAnalysisEngine_impl.java:183) at org.apache.uima.impl.AnalysisEngineFactory_impl.produceResource(Anal= ysisEngineFactory_impl.java:94) at org.apache.uima.impl.CompositeResourceFactory_impl.produceResource(C= ompositeResourceFactory_impl.java:62) at org.apache.uima.UIMAFramework.produceResource(UIMAFramework.java:258= ) at org.apache.uima.UIMAFramework.produceResource(UIMAFramework.java:303= ) at org.apache.uima.UIMAFramework.produceAnalysisEngine(UIMAFramework.ja= va:383) So this error indicate that UIMA can't find the a ResourceFactory to create= an AnalysisEngine from a .... descriptor.=20 What is the problem in the source code ? I think i've missed a step because= this Aggregate AE is working in a CPE.=20 Thanks=2C=20 Baptiste Gaillard _________________________________________________________________ In=E9dit ! Des Emotic=F4nes D=E9jant=E9es! Installez les dans votre Messeng= er !=20 http://www.ilovemessenger.fr/Emoticones/EmoticonesDejantees.aspx= --_ed886b82-f642-45b8-8029-65c05b3ef6e0_--