
In practice, a user must sometimes decide which processing branch an integration process is to continue in. The following example illustrates this:
An integration process collects requirements sent by various production facilities. A deadline is defined for collecting the requirements. If there are requirements that arrive after the deadline, an administrator must be able to decide on a case-by-case basis how the integration process is to continue.
Decision Options
To enable the user to make this kind of decision, add a step of type User Decision to the definition of the process. Then define the required decision options. The system inserts a processing branch for each decision option. You then insert the required processing steps in these processing branches.
Notification at Runtime
The intended user receives a dialog work item in the workflow inbox at runtime. This displays a corresponding button for each decision option that you defined. As soon as the user chooses a button, the system resumes the integration process in the relevant processing branch.
Local Variables
You can use variables when defining the texts that are displayed to the user at runtime. The system replaces these variables at runtime with the current data from the process. You can use existing container elements as variables, or define local variables.
You use a local variable to reference a particular field in a message. The system replaces the local variable at runtime with the current value of the field. By specifying a text with corresponding local variables, you can make the context of the decision clear to the agent, as shown in the following example:
Within a time limit of &deadline&, only ¤t_msg_count& messages out of a total of &msgt_total& have arrived. How should the process continue?
&msgt_total& could be a local variable that references a field in a message.
Note that in texts, you can only access the content of fields in a message by using local variables. It is not possible to enter XPath directly in the text.
In the title of the user decision, the system can replace a maximum of four variables with actual values.
Configurable Parameters for Specifying Agents
To determine which user is to be notified at runtime, you define a configurable parameter of type Agent and use it in the required user decisions.
At configuration time, you assign this configurable parameter to the relevant user in the Integration Directory. As a result, this user becomes the agent for all user decisions in which the corresponding configurable parameter is used. This means you can define user assignment centrally, and do not have to adjust each individual user decision following a modification.
The user that is to be entered as processor must be defined on the Integration Server.
Insert Step
Define Agent
Define Texts for User Decision
You can define the following texts:
Note that the system can replace a maximum of four variables in the title with actual values.
In this text, describe exactly what the agent needs to decide as part of the user decision. You can also provide notes about the processing steps that follow.
Insert Variables
You can insert existing container elements as variables, or define local variables. Only simple XSD data types are permitted for variables and local variables in texts.
Make sure that you provide the agent with sufficient information about the texts and variables, so that he or she can make a decision at runtime. This is particularly important for local variables that reference certain fields of a message.
You have the following options for inserting an existing container element as a variable:
To define a local variable, proceed as follows:
The local variable is now displayed under Local Variables in the properties area.
More information: Using the Expression Editor
More information: Integration Process Component