Handling connector exceptions
|
C-1075 Through an Integrator shape on a flow rule, a flow execution can call an external system such as a relational database, Enterprise JavaBean, or Web service. The activity referenced in the Integrator shape references a connector rule (for example, a Connect SOAP rule) that controls the communication and data exchange with the external system.
For various reasons, a tested connector interface may fail or time out, causing work item processing in the flow rule to halt. To facilitate detection and analysis or repair of such events, you can designate in your application a flow rule for connector exceptions. Failure of an Integrator shape causes the designated flow rule to start. The flow rule can send out email correspondence, attempt retries, skip over the integrated step, or send an assignment to someone.
See Using Error Handler Flows for Connectors, a document on the Integration area of the PDN, for detailed development instructions, summarized here.
To use this facility, specify the second key part — Flow Name — of a flow rule in the Error Handler Flow field on a connector rule form. PRPC uses the Applies To key part of the calling flow as the first key part when retrieving the exception flow rule.
If you leave the Error Handler Flow field blank, a connector problem causes the flow execution to fail and is reported only as Java exceptions in the Pega log of type: com.pega.pegarules.pub.services.ConnectorException
.
The standard flow rule Work-.ConnectionProblem provides a default approach to exception handling.
When you accept the default, a connector exception causes the following processing:
ResourceUnavailable
, processing continues in a FlowProblems flow. Use the Flow Errors gadget in the Processes landing page to address flow errors. See Process and Rules category — Processes.ResourceUnavailable
, up to five retries are attempted, at intervals determined by a service level rule.This flow may use a workbasket named IncompleteConnections@org.com. You can override this default with a flow rule (in your application's work classes) of the same name, or override the rules it calls. For example, your exception flow can send email notifications to an appropriate user.