"UIMAEE_exception__WARNING", e);
try {
sendReplyWithShutdownException(aCasReferenceId);
// getInProcessCache().destroy();
ErrorContext ec = new ErrorContext();
ec.add(ErrorContext.THROWABLE_ERROR, e);
ec.add(AsynchAEMessage.CasReference, aCasReferenceId);
handleAction(ErrorHandler.TERMINATE, null, ec);
} catch (Exception ex) {
if (UIMAFramework.getLogger(CLASS_NAME).isLoggable(Level.WARNING)) {
UIMAFramework.getLogger(CLASS_NAME).logrb(Level.WARNING, CLASS_NAME.getName(),
"executeFlowStep", UIMAEE_Constants.JMS_LOG_RESOURCE_BUNDLE,
"UIMAEE_service_exception_WARNING", getComponentName());
UIMAFramework.getLogger(CLASS_NAME).logrb(Level.WARNING, CLASS_NAME.getName(),
"executeFlowStep", UIMAEE_Constants.JMS_LOG_RESOURCE_BUNDLE,
"UIMAEE_exception__WARNING", e);
}
}
return;
}
if (UIMAFramework.getLogger(CLASS_NAME).isLoggable(Level.FINEST)) {
UIMAFramework.getLogger(CLASS_NAME).logrb(Level.FINEST, CLASS_NAME.getName(),
"executeFlowStep", UIMAEE_Constants.JMS_LOG_RESOURCE_BUNDLE, "UIMAEE_step__FINEST",
new Object[] { getComponentName(), aCasReferenceId });
}
try {
if (step instanceof SimpleStep) {
simpleStep((SimpleStep) step, aCasReferenceId);
} else if (step instanceof ParallelStep) {
parallelStep((ParallelStep) step, aCasReferenceId);
} else if (step instanceof FinalStep) {
// Special case: check if this CAS has just been produced by a Cas Multiplier.
// If so, we received a new CAS but there are no delegates in the pipeline.
// The CM was the last in the flow. In this case, set a property in the cache
// to simulate receipt of the reply to this CAS. This is so that the CAS is
// released in the finalStep() when the Aggregate is not a Cas Multiplier.
if (newCAS) {
CasStateEntry casStateEntry = localCache.lookupEntry(aCasReferenceId);
if (casStateEntry != null) {
casStateEntry.setReplyReceived();
}
}
finalStep((FinalStep) step, aCasReferenceId);
} else {
// catch all case. If we are here, there is a fatal configuration problem of the
// flow controller
UIMAFramework.getLogger(CLASS_NAME).logrb(Level.SEVERE, CLASS_NAME.getName(),
"executeFlowStep", UIMAEE_Constants.JMS_LOG_RESOURCE_BUNDLE,
"UIMAEE_invalid_step__SEVERE",
new Object[] { getComponentName(), step, aCasReferenceId });
throw new UIMARuntimeException(new Exception("Invalid Flow Step:"+step+" Object. Check Descriptor For Invalid AE Key" ));
}
if ( UIMAFramework.getLogger(CLASS_NAME).isLoggable(Level.FINEST)) {
UIMAFramework.getLogger(CLASS_NAME).logrb(Level.FINEST, CLASS_NAME.getName(),
"executeFlowStep", UIMAEE_Constants.JMS_LOG_RESOURCE_BUNDLE,
"UIMAEE_completed_step__FINEST",
new Object[] { getComponentName(), aCasReferenceId });
}
} catch (Exception e) {
// HashMap map = new HashMap();
// map.put(AsynchAEMessage.Command, AsynchAEMessage.Process);
// map.put(AsynchAEMessage.CasReference, aCasReferenceId);
ErrorContext ec = new ErrorContext();
ec.add(ErrorContext.THROWABLE_ERROR, e);
ec.add(AsynchAEMessage.CasReference, aCasReferenceId);
try {
handleAction(ErrorHandler.TERMINATE, null, ec);
} catch( Exception ex) {
UIMAFramework.getLogger(CLASS_NAME).logrb(Level.WARNING, CLASS_NAME.getName(),
"executeFlowStep", UIMAEE_Constants.JMS_LOG_RESOURCE_BUNDLE,