I know how to trigger a error boundary event in subprocess(class BoundaryErrorEventTest.java in project activiti-engine-examples), but how to trigger it in the task ? :?:For example……xml:
<serviceTask id="servicetask1" name="User Task" activiti:class="me.kafeitu.activiti.ErrorBoundaryEventAttachToTaskService"></serviceTask>
<boundaryEvent id="boundaryerror1" name="" cancelActivity="false" attachedToRef="servicetask1">
<errorEventDefinition errorRef="errorOne"></errorEventDefinition>
</boundaryEvent>
Java:
public class ErrorBoundaryEventAttachToTaskService implements JavaDelegate {
@Override
public void execute(DelegateExecution execution) throws Exception {
// TODO throw error for error boundary event
}
}