private void handleException(String errMsg) throws FaultException { log.error(errMsg); throw new FaultException(BAMPublisherConstants.BAM_FAULT, errMsg); }
@Override Node fetchVariableData(VariableInstance variable, boolean forWriting) throws FaultException { try { return super.fetchVariableData(variable, forWriting); } catch (FaultException fe) { if (forWriting) { fe = new FaultException(fe.getQName(), fe.getMessage(), new Throwable("throwUninitializedToVariable")); } throw fe; } }
throw new FaultException(_oevent.getOwner().constants.qnCorrelationViolation,"Correlation not initialized."); __log.error(e); if (_fault == null) { _fault = createFault(e.getQName(), _oevent);
} catch (FaultException fault) { if (aCopy.ignoreMissingFromData) { if (fault.getQName().equals(getOAsssign().getOwner().constants.qnSelectionFailure) && (fault.getCause() != null && "ignoreMissingFromData".equals(fault.getCause().getMessage()))) { continue; if (fault.getQName().equals(getOAsssign().getOwner().constants.qnUninitializedVariable) && (fault.getCause() == null || !"throwUninitializedToVariable".equals(fault.getCause().getMessage()))) { continue; faultData = createFault(fault.getQName(), aCopy, fault .getMessage()); break; } catch (ExternalVariableModuleException e) {
} catch(FaultException e){ __log.error("Fault while calculating due date: " + e.getQName() + "; Reason: " + e.getMessage()); _self.parent.completed(createFault(e.getQName(), _self.o), CompensationHandler.emptySet()); return; } catch (EvaluationException ee) {
public void completed(FaultData faultData, Set<CompensationHandler> compensations) { sendEvent(new ActivityExecEndEvent()); if (faultData != null) { dpe(_oactivity.sourceLinks); _self.parent.completed(faultData, compensations); } else { FaultData fault = null; for (Iterator<OLink> i = _oactivity.sourceLinks.iterator();i.hasNext();) { OLink olink = i.next(); LinkInfo linfo = _linkFrame.resolve(olink); try { boolean val = evaluateTransitionCondition(olink.transitionCondition); linfo.pub.linkStatus(val); } catch (FaultException e) { linfo.pub.linkStatus(false); __log.error(e); if (fault == null) fault = createFault(e.getQName(),olink.transitionCondition); } } _self.parent.completed(fault, compensations); } }
/** Constructor. */ public SCOPE(ActivityInfo self, ScopeFrame frame, LinkFrame linkFrame) { super(self, frame, linkFrame); _oscope = (OScope) self.o; assert _oscope.activity != null; // madars.vitolins _at gmail.com 2009.03.29 // inline variable initialization // Initialize variables at scope creation try{ initVars(); } catch (ExternalVariableModuleException e) { __log.error("Exception while doing inline external variable initialization", e); _self.parent.failure(e.toString(), null); return; } catch (FaultException e){ __log.error("Exception while doing inline variable initialization", e); _self.parent.failure(e.toString(), null); } }
value = _process.extractProperty(msg, alias, msg.toString()); } catch (FaultException fe) { String emsg = __msgs.msgPropertyAliasDerefFailedOnMessage(alias.getDescription(), fe.getMessage()); __log.error(emsg, fe); throw new InvalidMessageException(emsg, fe);
} catch (FaultException e) { __log.error(e); FaultData fault = createFault(e.getQName(), _opick, e.getMessage()); dpe(_opick.outgoingLinks); _self.parent.completed(fault, CompensationHandler.emptySet());
public void run() { Calendar alarm = Calendar.getInstance(); if (_oalarm.forExpr != null) try { getBpelRuntimeContext().getExpLangRuntime().evaluateAsDuration(_oalarm.forExpr, getEvaluationContext()).addTo(alarm); } catch (EvaluationException e) { throw new InvalidProcessException(e); } catch (FaultException e) { __log.error(e); _psc.completed(createFault(e.getQName(),_oalarm.forExpr), _comps); return; } else if (_oalarm.untilExpr != null) try { alarm.setTime(getBpelRuntimeContext().getExpLangRuntime().evaluateAsDate(_oalarm.untilExpr, getEvaluationContext()).getTime()); } catch (EvaluationException e) { throw new InvalidProcessException(e); } catch (FaultException e) { __log.error(e); _psc.completed(createFault(e.getQName(),_oalarm.untilExpr), _comps); return; } // We reduce to waiting for the alarm to be triggered. instance(new WAIT(alarm)); }
/** * We record all values of properties of a 'MessageType' variable for * efficient lookup. */ private void writeProperties(VariableInstance variable, Node value, XmlDataDAO dao) { if (variable.declaration.type instanceof OMessageVarType) { for (OProcess.OProperty property : variable.declaration.getOwner().properties) { OProcess.OPropertyAlias alias = property.getAlias(variable.declaration.type); if (alias != null) { try { String val = _bpelProcess.extractProperty((Element) value, alias, variable.declaration .getDescription()); if (val != null) { dao.setProperty(property.name.toString(), val); } } catch (FaultException e) { // This will fail as we're basically trying to extract properties on all // received messages for optimization purposes. if (__log.isDebugEnabled()) __log.debug("Couldn't extract property '" + property.toString() + "' in property pre-extraction: " + e.toString()); } } } } }
private void handleException(String errMsg, Throwable t) throws FaultException { log.error(errMsg, t); throw new FaultException(AnalyticsPublisherConstants.ANALYTICS_FAULT, errMsg, t); }
throw new FaultException(oswitch.getOwner().constants.qnSubLanguageExecutionFault, e.getMessage()); __log.error(e.getMessage(),e); faultData = createFault(e.getQName(), ocase); _self.parent.completed(faultData, CompensationHandler.emptySet());
} catch (FaultException e) { __log.error(e); FaultData fault = createFault(e.getQName(), _oinvoke); _self.parent.completed(fault, CompensationHandler.emptySet()); return; FaultData faultData = createFault(fault.getQName(), _oinvoke, fault.getMessage()); _self.parent.completed(faultData, CompensationHandler.emptySet());
} catch (FaultException e) { __log.error(e); fault = createFault(e.getQName(), oreply);
private void handleException(String errMsg, Throwable t) throws FaultException { log.error(errMsg, t); throw new FaultException(BAMPublisherConstants.BAM_FAULT, errMsg, t); }
public void run() { FaultData fault = null; if(_othrow.faultVariable != null){ try { sendVariableReadEvent(_scopeFrame.resolve(_othrow.faultVariable)); Node faultVariable = fetchVariableData(_scopeFrame.resolve(_othrow.faultVariable), false); fault = createFault(_othrow.faultName, (Element)faultVariable,_othrow.faultVariable.type,_othrow); } catch (FaultException e) { // deal with this as a fault (just not the one we hoped for) __log.error(e); fault = createFault(e.getQName(), _othrow); } }else{ fault = createFault(_othrow.faultName, _othrow); } _self.parent.completed(fault, CompensationHandler.emptySet()); } }
private void handleException(String errMsg) throws FaultException { log.error(errMsg); throw new FaultException(AnalyticsPublisherConstants.ANALYTICS_FAULT, errMsg); }
public void run() { boolean condResult = false; try { condResult = checkCondition(); } catch (FaultException fe) { __log.error(fe); _self.parent.completed(createFault(fe.getQName(), _self.o),_compHandlers); return; } if (condResult) { ActivityInfo child = new ActivityInfo(genMonotonic(), getOWhile().activity, newChannel(TerminationChannel.class), newChannel(ParentScopeChannel.class)); instance(createChild(child, _scopeFrame, _linkFrame)); instance(new WAITER(child)); } else /* stop. */ { _self.parent.completed(null, _compHandlers); } }
public Object evaluate(List args) throws XPathFunctionException { if (args.size() != 1) throw new XPathFunctionException(new FaultException(new QName(Namespaces.ODE_EXTENSION_NS, "getLinkStatusInvalidSource"), "Illegal Arguments")); OLink olink = _oxpath.links.get(args.get(0)); try { return _ectx.isLinkActive(olink) ? Boolean.TRUE : Boolean.FALSE; } catch (FaultException e) { throw new XPathFunctionException(new FaultException(new QName(Namespaces.ODE_EXTENSION_NS, "getLinkStatusInvalidSource"), e)); } } }