Designer 10.7 | webMethods Service Development Help | Building Flow Services | The EXIT Step | Exiting on Success or Failure
 
Exiting on Success or Failure
In an EXIT step, you indicate whether exiting should return a successful condition or a failure condition.
*Success indicates that the containing flow service or flow step executes successfully. Service execution continues based on the value of the Exit from property which indicates the iteration, flow step, or flow service from which the step exits.
You can exit and signal success to perform an abrupt completion of a flow step or service. Abrupt completion of a step is a transfer out of a flow step before its normal completion, which is execution all the way to the end of the step or containing step. Abrupt completion is not a failure. Execution will continue with the next iteration, flow step, or service in the flow service. The Exit from property determines from where the service exits and, consequently, how service execution continues.
Abrupt completion can be accomplished with an EXIT step configured to exit from $iteration, $loop, $flow, or $parent and signal success.
*Failure indicates that the flow service or flow step from which the EXIT step exits ends with failure. Signaling failure creates an exception that remains pending until it is caught or the flow completes. When a step exits with a failure, the failure is propagated to the parent step. Integration Server continues to propagate the failure until the failure is caught or control returns to a SEQUENCE step configured to exit on done. If the failure propagates to the top level of a flow and is not caught, Integration Server throws a FlowException. You can specify the exception that Integration Server throws and the text of the error message that is returned.
Note:
You can configure a flow service to catch and respond to an exception, including one thrown by an EXIT step, using the CATCH step as part of a TRY, CATCH, FINALLY usage pattern.
For information about normal completion, abrupt completion, and failure and how it affects the TRY, CATCH, and FINALLY steps, see Normal and Abrupt Completion and Failure of TRY, CATCH, and FINALLY Steps.