Software AG Products 10.7 | Integrating On-Premises and Cloud Applications | Integration Server Built-In Services | Flow Folder | Summary of Elements in this Folder | pub.flow:getLastError
 
pub.flow:getLastError
WmPublic. Obtains detailed information about the last exception that was trapped within a flow.
An exception is trapped in a flow when a service failure occurs inside a SEQUENCE step that executes until DONE, or when a service failure occurs inside a REPEAT step that repeats on FAILURE.
Input Parameters
None.
Output Parameters
lastError
Document Information about the last error, translated into the language used by the Integration Server. The structure of this document is defined by pub.event:exceptionInfo.
Usage Notes
If this service is not invoked from within a flow service, an exception is thrown.
Each execution of a service (whether the service succeeds or fails) updates the value returned by getLastError. Consequently, getLastError itself resets the value of lastError. Therefore, if the results of getLastError will be used as input to subsequent services, map the value of lastError to a variable in the pipeline.
If a map has multiple transformers, then a subsequent call to getLastError will return the error associated with the last failed transformer in the map, even if it is followed by successful transformers.
The pub.flow:getLastError services returns information for failures that originate in a service call made by flow only. The error information is not updated to reflect a failure caused by the EXIT step such as an EXIT step configured to exit $parent and signal failure.