Hi All,
I’m trying to catch exception using error boundary event. In my flow I have one service task on which I have one input variable which calls a java method which throw a exception and I want to catch that using boundary event but it’s not working. please help me here if know.
Below is the method I’m calling from Input variable
package com.example.workflow;
import org.camunda.bpm.engine.delegate.BpmnError;
import org.camunda.bpm.engine.delegate.DelegateExecution;
import org.springframework.stereotype.Component;
@Component("inputVariable")
public class InputVariable {
public String throughException(DelegateExecution execution) throws BpmnError{
// Simulate an error
System.out.println("exception Delegation called");
throw new BpmnError("Error_Code", "caught");
}
}
P.S- Find attached my BPMN
callActivityerror.bpmn (4.7 KB)