You are not looking at the latest version of the documentation. Check it out there.
You are looking at draft pre-release documentation for the next release of Flows for APEX. Product features documented here may not be released or may have different behavior to that documented here. You should not make any purchase decisions based on this draft documentation..

Terminate Events ( )

A terminate event ends the process level that it occurs in and all lower process levels. So a terminate end event in a main process level will terminate the complete process. A terminate end event in a sub process will end the sub process and any sub processes contained within it.

Terminate End Events can be used in a Flow model for two main purposes:

  • to trap process errors, and end model processing once an error is detected
  • to ensure that all elements in a complex model stop when the business process has finished.

Process End Status Flows for APEX allows you to specify the process instance status after a Terminate End Event. It can be either terminated or completed. For example, if your Terminate End Event is trapping a process error condition, and is causing the process to end in an abnormal state, you might want the instance status to be set as terminated; If the terminate end represents a normal (expected) process ending, you would want your instance to have a status of completed. The Flow Modeler properties panel allows you to specify which status should be used when the Terminate End Event is processed. (By default, it will be marked as completed).

Note: A Flow instance can also be terminated from the Flows for APEX PL/SQL API using the flow_terminate() call, which has the same effect as processing a Terminate End Event in a flow model. The Flow Modeler page of the Flows for APEX application allows an administrator to do this from its interface. An Instance which has been terminated from the API always has its instance state set as terminated.

Terminate End Event

Terminate End Events in a Sub Process.

Terminate End Events may also be put into in any sub-process diagram.

The behavior of a Terminate End Event in a sub process is to immediately end processing in the sub process, and return control to the next object in the immediate parent process.

Note that if the sub process has an error boundary event defined on it, the terminating sub process will NOT return to the error handler; it returns to the next event on the normal forward path.

Any nested child sub processes that are running below the the sub process containing the terminate end event, are also terminated.