public static void propagateError(BpmnError error, DelegateExecution execution) { propagateError(error.getErrorCode(), execution); }
public BpmnError(String errorCode, String message) { super(message); setErrorCode(errorCode); }
throw new BpmnError(errorCode, "No catching boundary event found for error with errorCode '" + errorCode + "', neither in same process nor in parent process");
protected void handleActivitiException(org.activiti.engine.ActivitiException e) { if (e instanceof org.activiti.engine.delegate.BpmnError) { org.activiti.engine.delegate.BpmnError activiti5BpmnError = (org.activiti.engine.delegate.BpmnError) e; throw new BpmnError(activiti5BpmnError.getErrorCode(), activiti5BpmnError.getMessage()); } else if (e instanceof org.activiti.engine.ActivitiClassLoadingException) { throw new FlowableClassLoadingException(e.getMessage(), e.getCause()); } else if (e instanceof org.activiti.engine.ActivitiObjectNotFoundException) { org.activiti.engine.ActivitiObjectNotFoundException activiti5ObjectNotFoundException = (org.activiti.engine.ActivitiObjectNotFoundException) e; throw new FlowableObjectNotFoundException(activiti5ObjectNotFoundException.getMessage(), activiti5ObjectNotFoundException.getObjectClass(), activiti5ObjectNotFoundException.getCause()); } else if (e instanceof org.activiti.engine.ActivitiOptimisticLockingException) { throw new FlowableOptimisticLockingException(e.getMessage()); } else if (e instanceof org.activiti.engine.ActivitiIllegalArgumentException) { throw new FlowableIllegalArgumentException(e.getMessage(), e.getCause()); } else { if (e.getCause() instanceof org.activiti.engine.ActivitiClassLoadingException) { throw new FlowableException(e.getMessage(), new FlowableClassLoadingException(e.getCause().getMessage(), e.getCause().getCause())); } else if (e.getCause() instanceof org.activiti.engine.ActivitiException) { throw new FlowableException(e.getMessage(), new FlowableException(e.getCause().getMessage(), e.getCause().getCause())); } else { throw new FlowableException(e.getMessage(), e.getCause()); } } }
@Override public void propagateError(BpmnError bpmnError, DelegateExecution execution) { try { org.activiti.engine.delegate.BpmnError activiti5BpmnError = new org.activiti.engine.delegate.BpmnError(bpmnError.getErrorCode(), bpmnError.getMessage()); ErrorPropagation.propagateError(activiti5BpmnError, (ActivityExecution) execution); } catch (org.activiti.engine.ActivitiException e) { handleActivitiException(e); } }
private static void executeCatchInSuperProcess(String errorCode, ActivityExecution superExecution) { String errorHandlerId = findLocalErrorEventHandler(superExecution, errorCode); if (errorHandlerId != null) { executeCatch(errorHandlerId, superExecution); } else { // no matching catch found, going one level up in process hierarchy ActivityExecution superSuperExecution = getSuperExecution(superExecution); if (superSuperExecution != null) { executeCatchInSuperProcess(errorCode, superSuperExecution); } else { throw new BpmnError(errorCode, "No catching boundary event found for error with errorCode '" + errorCode + "', neither in same process nor in parent process"); } } }
public BpmnError(String errorCode) { super(""); setErrorCode(errorCode); }
public static void propagateError(BpmnError error, ActivityExecution execution) { propagateError(error.getErrorCode(), execution); }
@Override @SuppressWarnings("all") public void executeImpl(DelegateExecution execution) throws Exception { if (activitiHelper.getExpressionVariableAsString(exceptionToThrow, execution) != null) { if (activitiHelper.getExpressionVariableAsString(exceptionToThrow, execution).equals(EXCEPTION_BPMN_ERROR)) { throw new BpmnError(EXCEPTION_BPMN_ERROR); } else if (activitiHelper.getExpressionVariableAsString(exceptionToThrow, execution).equals(EXCEPTION_RUNTIME)) { throw new RuntimeException(EXCEPTION_RUNTIME); } } } }
public BpmnError(String errorCode, String message) { super(message + " (errorCode='" + errorCode + "')"); setErrorCode(errorCode); }
public static void propagateError(BpmnError error, DelegateExecution execution) { propagateError(error.getErrorCode(), execution); }
throw new BpmnError(errorCode, "No catching boundary event found for error with errorCode '" + errorCode + "', neither in same process nor in parent process");
public BpmnError(String errorCode, String message) { super(message + " (errorCode='" + errorCode + "')"); setErrorCode(errorCode); }
public static void propagateError(BpmnError error, ActivityExecution execution) throws Exception { propagateError(error.getErrorCode(), execution); }
public static void propagateError(String errorCode, ActivityExecution execution) { while (execution != null) { String eventHandlerId = findLocalErrorEventHandler(execution, errorCode); if (eventHandlerId != null) { executeCatch(eventHandlerId, execution, errorCode); break; } if (execution.isProcessInstanceType()) { // dispatch process completed event if (Context.getProcessEngineConfiguration() != null && Context.getProcessEngineConfiguration().getEventDispatcher().isEnabled()) { Context.getProcessEngineConfiguration().getEventDispatcher().dispatchEvent( ActivitiEventBuilder.createEntityEvent(FlowableEngineEventType.PROCESS_COMPLETED_WITH_ERROR_END_EVENT, execution)); } } execution = getSuperExecution(execution); } if (execution == null) { throw new BpmnError(errorCode, "No catching boundary event found for error with errorCode '" + errorCode + "', neither in same process nor in parent process"); } }
public BpmnError(String errorCode, String message) { super(message); setErrorCode(errorCode); }
public BpmnError(String errorCode) { super(""); setErrorCode(errorCode); }
public BpmnError(String errorCode) { super(""); setErrorCode(errorCode); }
public BpmnError(String errorCode) { super(""); setErrorCode(errorCode); }