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/02/27 16:51:35 UTC
svn commit: r631623 - in
/incubator/uima/sandbox/trunk/uima-as/uimaj-as-activemq/src:
main/java/org/apache/uima/adapter/jms/activemq/
main/java/org/apache/uima/adapter/jms/client/
test/java/org/apache/uima/ee/test/ test/java/org/apache/uima/ee/test/utils/
Author: eae
Date: Wed Feb 27 07:51:23 2008
New Revision: 631623
URL: http://svn.apache.org/viewvc?rev=631623&view=rev
Log:
UIMA-809 commit Jerry's patches
Modified:
incubator/uima/sandbox/trunk/uima-as/uimaj-as-activemq/src/main/java/org/apache/uima/adapter/jms/activemq/SpringContainerDeployer.java
incubator/uima/sandbox/trunk/uima-as/uimaj-as-activemq/src/main/java/org/apache/uima/adapter/jms/activemq/UimaDefaultMessageListenerContainer.java
incubator/uima/sandbox/trunk/uima-as/uimaj-as-activemq/src/main/java/org/apache/uima/adapter/jms/client/BaseUIMAAsynchronousEngine_impl.java
incubator/uima/sandbox/trunk/uima-as/uimaj-as-activemq/src/test/java/org/apache/uima/ee/test/TestUimaEE.java
incubator/uima/sandbox/trunk/uima-as/uimaj-as-activemq/src/test/java/org/apache/uima/ee/test/utils/BaseTestSupport.java
Modified: incubator/uima/sandbox/trunk/uima-as/uimaj-as-activemq/src/main/java/org/apache/uima/adapter/jms/activemq/SpringContainerDeployer.java
URL: http://svn.apache.org/viewvc/incubator/uima/sandbox/trunk/uima-as/uimaj-as-activemq/src/main/java/org/apache/uima/adapter/jms/activemq/SpringContainerDeployer.java?rev=631623&r1=631622&r2=631623&view=diff
==============================================================================
--- incubator/uima/sandbox/trunk/uima-as/uimaj-as-activemq/src/main/java/org/apache/uima/adapter/jms/activemq/SpringContainerDeployer.java (original)
+++ incubator/uima/sandbox/trunk/uima-as/uimaj-as-activemq/src/main/java/org/apache/uima/adapter/jms/activemq/SpringContainerDeployer.java Wed Feb 27 07:51:23 2008
@@ -188,7 +188,7 @@
ApplicationContext ctx = new FileSystemXmlApplicationContext(springContextFile);
return initializeContainer(ctx);
} catch (ResourceInitializationException e) {
- e.printStackTrace();
+ //e.printStackTrace();
throw e;
} catch (Exception e) {
e.printStackTrace();
Modified: incubator/uima/sandbox/trunk/uima-as/uimaj-as-activemq/src/main/java/org/apache/uima/adapter/jms/activemq/UimaDefaultMessageListenerContainer.java
URL: http://svn.apache.org/viewvc/incubator/uima/sandbox/trunk/uima-as/uimaj-as-activemq/src/main/java/org/apache/uima/adapter/jms/activemq/UimaDefaultMessageListenerContainer.java?rev=631623&r1=631622&r2=631623&view=diff
==============================================================================
--- incubator/uima/sandbox/trunk/uima-as/uimaj-as-activemq/src/main/java/org/apache/uima/adapter/jms/activemq/UimaDefaultMessageListenerContainer.java (original)
+++ incubator/uima/sandbox/trunk/uima-as/uimaj-as-activemq/src/main/java/org/apache/uima/adapter/jms/activemq/UimaDefaultMessageListenerContainer.java Wed Feb 27 07:51:23 2008
@@ -114,7 +114,6 @@
protected void handleListenerException( Throwable t )
{
- t.printStackTrace();
String endpointName =
(getDestination() == null) ? "" : ((ActiveMQDestination)getDestination()).getPhysicalName();
Modified: incubator/uima/sandbox/trunk/uima-as/uimaj-as-activemq/src/main/java/org/apache/uima/adapter/jms/client/BaseUIMAAsynchronousEngine_impl.java
URL: http://svn.apache.org/viewvc/incubator/uima/sandbox/trunk/uima-as/uimaj-as-activemq/src/main/java/org/apache/uima/adapter/jms/client/BaseUIMAAsynchronousEngine_impl.java?rev=631623&r1=631622&r2=631623&view=diff
==============================================================================
--- incubator/uima/sandbox/trunk/uima-as/uimaj-as-activemq/src/main/java/org/apache/uima/adapter/jms/client/BaseUIMAAsynchronousEngine_impl.java (original)
+++ incubator/uima/sandbox/trunk/uima-as/uimaj-as-activemq/src/main/java/org/apache/uima/adapter/jms/client/BaseUIMAAsynchronousEngine_impl.java Wed Feb 27 07:51:23 2008
@@ -200,7 +200,11 @@
{
consumerSession.close();
consumer.close();
- connection.close();
+ try
+ {
+ connection.close();
+ }
+ catch(Exception ex) {}
connection = null;
}
if ( jmxManager != null )
Modified: incubator/uima/sandbox/trunk/uima-as/uimaj-as-activemq/src/test/java/org/apache/uima/ee/test/TestUimaEE.java
URL: http://svn.apache.org/viewvc/incubator/uima/sandbox/trunk/uima-as/uimaj-as-activemq/src/test/java/org/apache/uima/ee/test/TestUimaEE.java?rev=631623&r1=631622&r2=631623&view=diff
==============================================================================
--- incubator/uima/sandbox/trunk/uima-as/uimaj-as-activemq/src/test/java/org/apache/uima/ee/test/TestUimaEE.java (original)
+++ incubator/uima/sandbox/trunk/uima-as/uimaj-as-activemq/src/test/java/org/apache/uima/ee/test/TestUimaEE.java Wed Feb 27 07:51:23 2008
@@ -212,6 +212,7 @@
BaseUIMAAsynchronousEngine_impl eeUimaEngine = new BaseUIMAAsynchronousEngine_impl();
deployService(eeUimaEngine, relativePath+"/Deploy_PersonTitleAnnotator.xml");
Map<String, Object> appCtx = buildContext( String.valueOf(broker.getMasterConnectorURI()),"PersonTitleAnnotatorQueue" );
+ super.setExpectingServiceShutdown();
initialize(eeUimaEngine, appCtx);
waitUntilInitialized();
try
@@ -249,6 +250,7 @@
BaseUIMAAsynchronousEngine_impl eeUimaEngine = new BaseUIMAAsynchronousEngine_impl();
deployService(eeUimaEngine, relativePath+"/Deploy_NoOpAnnotatorWithException.xml");
deployService(eeUimaEngine, relativePath+"/Deploy_AggregateWithFlowControllerExceptionOnDisable.xml");
+ super.setExpectingServiceShutdown();
runTest(null,eeUimaEngine,String.valueOf(broker.getMasterConnectorURI()),"TopLevelTaeQueue", 1, EXCEPTION_LATCH); //PC_LATCH);
}
@@ -424,6 +426,7 @@
BaseUIMAAsynchronousEngine_impl eeUimaEngine = new BaseUIMAAsynchronousEngine_impl();
deployService(eeUimaEngine, relativePath+"/Deploy_NoOpAnnotator.xml");
deployService(eeUimaEngine, relativePath+"/Deploy_ComplexAggregate.xml");
+ super.setExpectingServiceShutdown();
runTest(null,eeUimaEngine,String.valueOf(broker.getMasterConnectorURI()),"TopLevelTaeQueue", 0, PROCESS_LATCH);
}
@@ -453,6 +456,7 @@
deployService(eeUimaEngine, relativePath+"/Deploy_RemoteCasMultiplier.xml");
deployService(eeUimaEngine, relativePath+"/Deploy_NoOpAnnotatorWithExceptionOn5thCAS.xml");
deployService(eeUimaEngine, relativePath+"/Deploy_AggregateWithRemoteMultiplier.xml");
+ super.setExpectingServiceShutdown();
runTest(null, eeUimaEngine,String.valueOf(broker.getMasterConnectorURI()),"TopLevelTaeQueue", 1, EXCEPTION_LATCH);
}
@@ -474,6 +478,7 @@
deployService(eeUimaEngine, relativePath+"/Deploy_RemoteCasMultiplierWith1MillionDocs.xml");
deployService(eeUimaEngine, relativePath+"/Deploy_NoOpAnnotator.xml");
deployService(eeUimaEngine, relativePath+"/Deploy_AggregateWithRemoteMultiplier.xml");
+ super.setExpectingServiceShutdown();
// Spin a thread to cancel Process after 20 seconds
spinShutdownThread( eeUimaEngine, 20000 );
runTest(null, eeUimaEngine,String.valueOf(broker.getMasterConnectorURI()),"TopLevelTaeQueue", 1,EXCEPTION_LATCH);
@@ -494,6 +499,7 @@
BaseUIMAAsynchronousEngine_impl eeUimaEngine = new BaseUIMAAsynchronousEngine_impl();
// Deploy remote service
deployService(eeUimaEngine, relativePath+"/Deploy_NoOpAnnotatorWithException.xml");
+ super.setExpectingServiceShutdown();
// Deploy Uima EE Primitive Service
// Initialize and run the Test. Wait for a completion and cleanup resources.
runTest(null,eeUimaEngine,String.valueOf(broker.getMasterConnectorURI()),"NoOpAnnotatorQueue", 1, EXCEPTION_LATCH);
@@ -512,6 +518,7 @@
// Deploy top level aggregate service
deployService(eeUimaEngine, relativePath+"/Deploy_AggregateWithParallelFlowTerminateOnDelegateFailure.xml");
+ super.setExpectingServiceShutdown();
// Initialize and run the Test. Wait for a completion and cleanup resources.
runTest(null,eeUimaEngine,String.valueOf(broker.getMasterConnectorURI()),"TopLevelTaeQueue", 1, EXCEPTION_LATCH); //PC_LATCH);
@@ -538,6 +545,7 @@
deployService(eeUimaEngine, relativePath+"/Deploy_NoOpAnnotator.xml");
// Deploy top level aggregate service
deployService(eeUimaEngine, relativePath+"/Deploy_AggregateAnnotator.xml");
+ super.setExpectingServiceShutdown();
// Initialize and run the Test. Wait for a completion and cleanup resources.
runTest(null,eeUimaEngine,String.valueOf(broker.getMasterConnectorURI()),"TopLevelTaeQueue", 1, CPC_LATCH );
}
@@ -551,6 +559,7 @@
BaseUIMAAsynchronousEngine_impl eeUimaEngine = new BaseUIMAAsynchronousEngine_impl();
// Deploy remote service
deployService(eeUimaEngine, relativePath+"/Deploy_NoOpAnnotator.xml");
+ super.setExpectingServiceShutdown();
// Initialize and run the Test. Wait for a completion and cleanup resources.
runTest(null,eeUimaEngine,httpURI,"NoOpAnnotatorQueue", 1, CPC_LATCH );
}
@@ -566,6 +575,7 @@
deployService(eeUimaEngine, relativePath+"/Deploy_NoOpAnnotator.xml");
// Deploy top level aggregate that communicates with the remote via Http Tunnelling
deployService(eeUimaEngine, relativePath+"/Deploy_AggregateAnnotatorWithHttpDelegate.xml");
+ super.setExpectingServiceShutdown();
// Initialize and run the Test. Wait for a completion and cleanup resources.
runTest(null,eeUimaEngine, String.valueOf(broker.getMasterConnectorURI()), "TopLevelTaeQueue", 10, CPC_LATCH );
@@ -627,6 +637,7 @@
initialize(eeUimaEngine, appCtx);
// Wait until the top level service returns its metadata
waitUntilInitialized();
+ super.setExpectingServiceShutdown();
CAS cas = eeUimaEngine.getCAS();
System.out.println(" Sending CAS to kick off aggregate w/colocated CasMultiplier");
@@ -721,6 +732,7 @@
deployService(eeUimaEngine, relativePath+"/Deploy_NoOpAnnotator.xml");
// Deploy top level aggregate that communicates with the remote via Http Tunnelling
deployService(eeUimaEngine, relativePath+"/Deploy_AggregateAnnotatorWithHttpDelegateNoRetries.xml");
+ super.setExpectingServiceShutdown();
runTest(null,eeUimaEngine, String.valueOf(broker.getMasterConnectorURI()), "TopLevelTaeQueue", 10, EXCEPTION_LATCH );
fail("Expected ResourceInitializationException. Instead, the Aggregate Reports Successfull Initialization");
}
Modified: incubator/uima/sandbox/trunk/uima-as/uimaj-as-activemq/src/test/java/org/apache/uima/ee/test/utils/BaseTestSupport.java
URL: http://svn.apache.org/viewvc/incubator/uima/sandbox/trunk/uima-as/uimaj-as-activemq/src/test/java/org/apache/uima/ee/test/utils/BaseTestSupport.java?rev=631623&r1=631622&r2=631623&view=diff
==============================================================================
--- incubator/uima/sandbox/trunk/uima-as/uimaj-as-activemq/src/test/java/org/apache/uima/ee/test/utils/BaseTestSupport.java (original)
+++ incubator/uima/sandbox/trunk/uima-as/uimaj-as-activemq/src/test/java/org/apache/uima/ee/test/utils/BaseTestSupport.java Wed Feb 27 07:51:23 2008
@@ -572,7 +572,7 @@
}
catch (Exception e)
{
- e.printStackTrace();
+ //e.printStackTrace();
}
}
}