Invoke system function

Use the Invoke system function to request a Web Service. See About Web Services for information about using Web Services in workflows.

NOTE  Prior to defining the Invoke system function, you must specify the Partner Links in the Workflow Properties.

General properties

To specify the general properties for the Invoke system function

  1. From the Web Services step palette, drag an Invoke step onto the workflow map.

    See About system steps for information about including multiple system functions in a single step.

  2. On the Invoke General tab, select the Partner Link for the Web Service. The Partner Links list contains only entries specified for Invoke in Workflow Properties Web Services.

    See the note at the end of this topic for information regarding partner links that are modified after the parameters are defined for an Invoke system function.

  3. Select the appropriate Operation in the Web Service.
  4. Under Message Type, select Parameters or XML.

    Parameters - use workflow data fields and attachments for input and output. This option is available for simple parameters and for schemas up to two levels deep.

    XML - use XML messages for input and output. This option must be used for nested parameters more than two levels deep.

Advanced properties

Timeout handling

You can specify a timeout expression that will provide alternative processing after a specified amount of time.

  1. On the Advanced tab, enter a time expression to specify the wait time.

    For example, you can enter a time function such as

    addminutes(systemtime(), 30)

    This allows the step to wait 30 minutes before it goes to the specified timeout map.

  2. Select an appropriate submap to be executed if the timeout condition occurs. You can choose one of the system maps (Terminate or Malfunction), or you can create your own submap.

NOTE   This timeout expression does not apply when the web service request is successfully invoked. When a work item is queued to the WSRequest queue, the timeout commences until the WSRequest queue sends the web service request to the web service. Once the web service request is issued, the timeout expression no longer applies. Additionally, if the web service request is sent within the timeout period, the timeout processing will not occur even if the web service is delayed in sending back an expected reply.

Reliable messaging

You can use WS-ReliableMessaging technology to provide assurance that an Invoke message that is sent will be received by the target Web Service. To achieve the reliability, a standardized series of messages is exchanged between the sender and the receiver. In addition, each message is sent repeatedly until the expected acknowledgement message is received. See About WS-ReliableMessaging for information about FileNet's implementation of this technology.

NOTE   WS-ReliableMessaging results in a minimum of five messages for every request, plus additional messages if retransmissions are necessary. Therefore, IBM recommends that you use WS-ReliableMessaging only for requests that warrant this type of handling.

To specify WS-Reliable Messaging for the Invoke function

NOTE  

TIP If the message is not delivered in the specified time limit, a fault will be returned in the same manner as for standard requests. For a reliable messaging request, the fault message includes the current state of the reliable message invocation, which helps to identify where the problems is occurring. Therefore, to realize the benefit of this technology, IBM recommends that you use the fault handling options (described below) to handle any faults in an appropriate manner.

Fault handling

On the Faults tab, you can specify string fields or XML data fields to hold a fault message, and submaps to execute for faults specified by the Web Service, or for other faults.

NOTE  The fault message returned will not include Process Engine exception codes, only the exception message.

Correlation set

In XML mode, you can specify one or more properties that will be used to identify a runtime conversation between two processes. For example, with Web Services involving purchase orders, there might be several exchanges of messages between the buyer and the seller, so you need to ensure that each message stays with the appropriate conversation. (If you are using Parameter mode, the Correlation Set tab is available for Receive, but not for Invoke.)

  1. On the Correlation Set tab, specify a name for this correlation set.
  2. Under Properties, specify a name and the XPath Query to the appropriate element in the schema. You can specify more than one name/XPath Query pair to define the correlation expression. For example, you might use a combination of an account number and an invoice number.

When you specify a correlation set for Invoke, the F_Corr<Correlation_Set_Name> field is set to the value specified by the XPath query.

See Using Web Services in FileNet workflows for examples of invoking and receiving Web Services requests.

NOTE  If a partner link's endpoint is changed (for example, if you update the partner link by selecting a different version of a workflow with the corresponding Receive system function), Process Designer inspects each Invoke system function in the current workflow and updates them as follows: