Error Event

An Error event indicates a failure of a task or subprocess.

error boundary event

Error Event on a Task

An Error boundary event on a Service or Business Rule task means the invoked service returned a fault message and error code, which can be mapped to a data object using data output mapping. An Error boundary event is always interrupting. The exception flow from the Error event is the handler for the reported error.

To configure the event, use the Attributes/Error Event context menu action.

error event config

The error code attribute is used to decide which HTTP code is returned by the service:

  • numeric error codes within the range of 100 to 999 will be directly set as response code on the service response (HTTP response)

  • non-numeric or outside of the above range will be represented as 500 service response.

When using numeric error code there is a probability of selecting a code that is already used by the engine e.g. 401 (that is used to indicate not authorized). In that case, the service definition (OpenAPI) will indicate that the HTTP code could return either of the responses.

Error Event on a Subprocess

error end event

An Error boundary event on a subprocess catches the Error trigger thrown by an Error end event in the child level of the subprocess, and the exception flow from the boundary event models the handler for the error.

event 12

To configure an Error end event for automation, use the Attributes/Error Event context menu action. The error name and an error code are mandatory. When the end event is reached, the defined error trigger is thrown.

Error end events can be used to indicate a business error that will be considered a valid response of the service.

When an error end event is processed, service response will only include the data mapped to the error end event and no other data outputs. Thus it is recommended to always map relevant data to error end events to provide meaningful service response.

Retry on Error Policy

The Retry On Error Policy attribute allows you to define an interval and maximum number of attempts for the engine to retry a failing task.

It can be defined globally on the process and/or on each task. To do so, right click on your process or your task and select "Retry On Error Policy…​" in the sub-menu.

retry on error 1

The Retry On Error Policy applies only when interval and maximum attempts are all filled.

If it is enabled at the process level, it is possible to override the policy on each task with new values or to specify that we will not retry this specific task.