You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@uima.apache.org by ea...@apache.org on 2008/08/19 23:22:04 UTC

svn commit: r687161 - in /incubator/uima/sandbox/branches/uima-as-post1st/uimaj-as-activemq/src/test: java/org/apache/uima/ee/test/ resources/deployment/ resources/descriptors/analysis_engine/

Author: eae
Date: Tue Aug 19 14:22:04 2008
New Revision: 687161

URL: http://svn.apache.org/viewvc?rev=687161&view=rev
Log:
UIMA-1132 Commit Jerry's patch

Added:
    incubator/uima/sandbox/branches/uima-as-post1st/uimaj-as-activemq/src/test/resources/deployment/Deploy_AggregateWithLastCM.xml
    incubator/uima/sandbox/branches/uima-as-post1st/uimaj-as-activemq/src/test/resources/descriptors/analysis_engine/SimpleTestAggregateWithLastCasMultiplier.xml
Modified:
    incubator/uima/sandbox/branches/uima-as-post1st/uimaj-as-activemq/src/test/java/org/apache/uima/ee/test/TestUimaASExtended.java

Modified: incubator/uima/sandbox/branches/uima-as-post1st/uimaj-as-activemq/src/test/java/org/apache/uima/ee/test/TestUimaASExtended.java
URL: http://svn.apache.org/viewvc/incubator/uima/sandbox/branches/uima-as-post1st/uimaj-as-activemq/src/test/java/org/apache/uima/ee/test/TestUimaASExtended.java?rev=687161&r1=687160&r2=687161&view=diff
==============================================================================
--- incubator/uima/sandbox/branches/uima-as-post1st/uimaj-as-activemq/src/test/java/org/apache/uima/ee/test/TestUimaASExtended.java (original)
+++ incubator/uima/sandbox/branches/uima-as-post1st/uimaj-as-activemq/src/test/java/org/apache/uima/ee/test/TestUimaASExtended.java Tue Aug 19 14:22:04 2008
@@ -368,6 +368,22 @@
 	    appCtx.put(UimaAsynchronousEngine.ReplyWindow, 1);
 	    runTest(appCtx,eeUimaEngine,String.valueOf(broker.getMasterConnectorURI()),"TopLevelTaeQueue", 1, PROCESS_LATCH, true);
 	}
+	/**
+	 * Tests Aggregate configuration where the Cas Multiplier delegate is the
+	 * last delegate in the Aggregate's pipeline 
+	 *   
+	 * @throws Exception
+	 */
+	public void testAggregateProcessCallWithLastCM() throws Exception
+	{
+		
+	    System.out.println("-------------- testAggregateProcessCallWithLastCM -------------");
+		BaseUIMAAsynchronousEngine_impl eeUimaEngine = new BaseUIMAAsynchronousEngine_impl();
+		//	Deploy Uima EE Primitive Services each with 6000ms delay in process()
+		deployService(eeUimaEngine, relativePath+"/Deploy_AggregateWithLastCM.xml");
+		super.setExpectingServiceShutdown();
+	    runTest(null,eeUimaEngine,String.valueOf(broker.getMasterConnectorURI()),"TopLevelTaeQueue", 1, PROCESS_LATCH, true);
+	}
 
 	/**
 	 * Tests shutdown while running with multiple/concurrent threads

Added: incubator/uima/sandbox/branches/uima-as-post1st/uimaj-as-activemq/src/test/resources/deployment/Deploy_AggregateWithLastCM.xml
URL: http://svn.apache.org/viewvc/incubator/uima/sandbox/branches/uima-as-post1st/uimaj-as-activemq/src/test/resources/deployment/Deploy_AggregateWithLastCM.xml?rev=687161&view=auto
==============================================================================
--- incubator/uima/sandbox/branches/uima-as-post1st/uimaj-as-activemq/src/test/resources/deployment/Deploy_AggregateWithLastCM.xml (added)
+++ incubator/uima/sandbox/branches/uima-as-post1st/uimaj-as-activemq/src/test/resources/deployment/Deploy_AggregateWithLastCM.xml Tue Aug 19 14:22:04 2008
@@ -0,0 +1,52 @@
+<?xml version="1.0" encoding="UTF-8"?>
+  <!--
+   ***************************************************************
+   * Licensed to the Apache Software Foundation (ASF) under one
+   * or more contributor license agreements.  See the NOTICE file
+   * distributed with this work for additional information
+   * regarding copyright ownership.  The ASF licenses this file
+   * to you under the Apache License, Version 2.0 (the
+   * "License"); you may not use this file except in compliance
+   * with the License.  You may obtain a copy of the License at
+         *
+   *   http://www.apache.org/licenses/LICENSE-2.0
+   * 
+   * Unless required by applicable law or agreed to in writing,
+   * software distributed under the License is distributed on an
+   * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+   * KIND, either express or implied.  See the License for the
+   * specific language governing permissions and limitations
+   * under the License.
+   ***************************************************************
+   -->
+<analysisEngineDeploymentDescription xmlns="http://uima.apache.org/resourceSpecifier">
+  <name>Top Level TAE</name>
+  <description/>
+  <version/>
+  <vendor/>
+  <deployment protocol="jms" provider="activemq">
+    <casPool numberOfCASes="3" initialFsHeapSize="2000000"/> 
+    <service>
+      <inputQueue endpoint="TopLevelTaeQueue" brokerURL="tcp://localhost:8118" prefetch="0"/>
+      <topDescriptor>
+        <import location="../descriptors/analysis_engine/SimpleTestAggregateWithLastCasMultiplier.xml"/>
+      </topDescriptor>
+      <analysisEngine async="true">
+        <delegates>
+          <analysisEngine key="TestMultiplier" async="false">
+            <casMultiplier poolSize="4" initialFsHeapSize="2000000"/>
+            <asyncAggregateErrorConfiguration>
+              <getMetadataErrors maxRetries="0" timeout="0" errorAction="terminate"/>
+              <processCasErrors maxRetries="0" timeout="0" continueOnRetryFailure="false" thresholdCount="0" thresholdWindow="0" thresholdAction="terminate"/>
+              <collectionProcessCompleteErrors timeout="0" additionalErrorAction="terminate"/>
+            </asyncAggregateErrorConfiguration>
+          </analysisEngine>
+	    </delegates>
+        <asyncPrimitiveErrorConfiguration>
+          <processCasErrors thresholdCount="0" thresholdWindow="0" thresholdAction="terminate"/>
+          <collectionProcessCompleteErrors timeout="0" additionalErrorAction="terminate"/>
+        </asyncPrimitiveErrorConfiguration>
+      </analysisEngine>
+    </service>
+  </deployment>
+</analysisEngineDeploymentDescription>

Added: incubator/uima/sandbox/branches/uima-as-post1st/uimaj-as-activemq/src/test/resources/descriptors/analysis_engine/SimpleTestAggregateWithLastCasMultiplier.xml
URL: http://svn.apache.org/viewvc/incubator/uima/sandbox/branches/uima-as-post1st/uimaj-as-activemq/src/test/resources/descriptors/analysis_engine/SimpleTestAggregateWithLastCasMultiplier.xml?rev=687161&view=auto
==============================================================================
--- incubator/uima/sandbox/branches/uima-as-post1st/uimaj-as-activemq/src/test/resources/descriptors/analysis_engine/SimpleTestAggregateWithLastCasMultiplier.xml (added)
+++ incubator/uima/sandbox/branches/uima-as-post1st/uimaj-as-activemq/src/test/resources/descriptors/analysis_engine/SimpleTestAggregateWithLastCasMultiplier.xml Tue Aug 19 14:22:04 2008
@@ -0,0 +1,43 @@
+<analysisEngineDescription xmlns="http://uima.apache.org/resourceSpecifier">
+  <frameworkImplementation>org.apache.uima.java</frameworkImplementation>
+  <primitive>false</primitive>
+  <delegateAnalysisEngineSpecifiers>
+    
+    <delegateAnalysisEngine key="TestMultiplier">
+      <import location="../multiplier/SimpleCasGeneratorProducing10Cases.xml"/>
+    </delegateAnalysisEngine>
+
+
+      <delegateAnalysisEngine key="NoOp">
+      <import location="NoOpAnnotator.xml"/>
+    </delegateAnalysisEngine>
+  
+  </delegateAnalysisEngineSpecifiers>
+  <analysisEngineMetaData>
+    <name>Test Aggregate TAE</name>
+    <description>Detects Nothing</description>
+    <configurationParameters/>
+    <configurationParameterSettings/>
+    <flowConstraints>
+      <fixedFlow>
+        <node>NoOp</node> 
+        <node>TestMultiplier</node>
+      </fixedFlow>
+    </flowConstraints>
+    <capabilities>
+      <capability>
+        <inputs/>
+        <outputs>
+        </outputs>
+        <languagesSupported>
+          <language>en</language>
+        </languagesSupported>
+      </capability>
+    </capabilities>
+	<operationalProperties>
+		<modifiesCas>true</modifiesCas>
+		<multipleDeploymentAllowed>true</multipleDeploymentAllowed>
+		<outputsNewCASes>false</outputsNewCASes>
+	</operationalProperties>
+  </analysisEngineMetaData>
+</analysisEngineDescription>