Hi Baptiste,
I'm having a problem recreating the problem. Maybe I don't understand the
scenario correctly. Here's what I did initially to debug the problem:
1. create an eclipse workspace with the uimaj-examples project.
2. create a second project with just the SofaExampleAnnotator source
and descriptor.
3. Create a pear file with the SofaExampleAnnotator source and descriptor
4. create an aggregate descriptor in the new project that wraps either the
SofaExampleAnnotator or the pear file, and declares Sofa mapping
to map _InitialView into EnglishDocument
5. run the aggregate using CVD
Using the 2.2.2 release, the aggregate wrapping SofaExampleAnnotator works,
but it fails when wrapping the pear file.
To fix the pear problem, I imported uimaj-core as a new project in the workspace
and modified the code (1107 fix). Then, I modified the CVD run configuration to
include the uimaj-core project in the front. This worked, and continues to work
for me using the latest uimaj-core from the trunk.
To mimic your new scenario, I created a second aggregate that has two
delegates: first SofaExampleAnnotator and then the pear annotator.
Sofa mapping was set so that the first annotator read from _InitialView
and wrote to GarbageDocument, and the second annotator read from
GarbageDocument and wrote to GermanDocument. After running,
CVD showed the following view text:
_InitialView: this beer is good
GarbageDocument: das bier ist gut
GermanDocument: gut gut gut gut
Here is the aggregate descriptor:
<?xml version="1.0" encoding="UTF-8"?>
<analysisEngineDescription xmlns="http://uima.apache.org/resourceSpecifier">
<frameworkImplementation>org.apache.uima.java</frameworkImplementation>
<primitive>false</primitive>
<delegateAnalysisEngineSpecifiers>
<delegateAnalysisEngine key="ProjectForPear_pear">
<import location="../ProjectForPear/ProjectForPear_pear.xml"/>
</delegateAnalysisEngine>
<delegateAnalysisEngine key="SofaExampleAnnotator">
<import
location="../../uimaj-examples/descriptors/analysis_engine/SofaExampleAnnotator.xml"/>
</delegateAnalysisEngine>
</delegateAnalysisEngineSpecifiers>
<analysisEngineMetaData>
<name>SofaMapTestAggregate</name>
<description/>
<version>1.0</version>
<vendor/>
<configurationParameters/>
<configurationParameterSettings/>
<flowConstraints>
<fixedFlow>
<node>SofaExampleAnnotator</node>
<node>ProjectForPear_pear</node>
</fixedFlow>
</flowConstraints>
<fsIndexCollection/>
<capabilities>
<capability>
<inputs/>
<outputs/>
<inputSofas>
<sofaName>_InitialView</sofaName>
</inputSofas>
<outputSofas>
<sofaName>GermanDocument</sofaName>
<sofaName>GarbageDocument</sofaName>
</outputSofas>
<languagesSupported/>
</capability>
</capabilities>
<operationalProperties>
<modifiesCas>true</modifiesCas>
<multipleDeploymentAllowed>true</multipleDeploymentAllowed>
<outputsNewCASes>false</outputsNewCASes>
</operationalProperties>
</analysisEngineMetaData>
<resourceManagerConfiguration/>
<sofaMappings>
<sofaMapping>
<componentKey>SofaExampleAnnotator</componentKey>
<componentSofaName>EnglishDocument</componentSofaName>
<aggregateSofaName>_InitialView</aggregateSofaName>
</sofaMapping>
<sofaMapping>
<componentKey>SofaExampleAnnotator</componentKey>
<componentSofaName>GermanDocument</componentSofaName>
<aggregateSofaName>GarbageDocument</aggregateSofaName>
</sofaMapping>
<sofaMapping>
<componentKey>ProjectForPear_pear</componentKey>
<componentSofaName>EnglishDocument</componentSofaName>
<aggregateSofaName>GarbageDocument</aggregateSofaName>
</sofaMapping>
<sofaMapping>
<componentKey>ProjectForPear_pear</componentKey>
<componentSofaName>GermanDocument</componentSofaName>
<aggregateSofaName>GermanDocument</aggregateSofaName>
</sofaMapping>
</sofaMappings>
</analysisEngineDescription>
Sorry to be slow getting to this issue. Regards,
Eddie
On Thu, Oct 16, 2008 at 3:01 PM, Baptiste Gaillard
<[EMAIL PROTECTED]> wrote:
>
> Hi,
>
> As Aaron said in his previous message the problem should have been fixed :
>
> https://issues.apache.org/jira/browse/UIMA-1107
>
> But I tested again my aggregate, Aaron too.
> We found that the BUG appears again now.
>
> Because I absolutely need to fix this BUG I tried to debug a very simple
> workflow which integrate an aggregate.
>
> I am in the same situation , I integrate 2 annotators in an aggregate, the
> first creates a new Sofa and the second works on this created Sofa.
>
> I found that when the two annotators of my aggregate are declared using the
> '_pear.xml' descriptor, in the second annotator the CAS has a 'mSofaMappings'
> (in fact JCasImpl.casImpl.svd.componentInfo.mSofaMappings) member empty (but
> it should not !).
>
> componentInfo is of type RootUimaContext_Impl
>
> When the second annotator is declared with the component descriptor (not the
> '_pear.xml' one) the 'mSofaMappings' contains
> {_InitialView=MY_PRODUCED_SOFA}, so it seams right in this case.
>
> I search during hours to find why this 'mSofaMappings' is empty without
> success.
>
> So, could you give me clues to help me find the problem ? What could be the
> responsible classes ?
>
> If you want I cant send you my simple workflow to test that thing.
>
> Thanks for your help,
>
> Baptiste
>
>