Setting up a Call Activity

During the course of a process, it is possible to call another process by transmitting (or not) input data to it.

For example:

The above process is used to report a school’s stock of school supplies. If the quantity of a supply is less than 100 units, then the purchase requisition process is triggered. Finally, an email is sent with the stock status (current or after purchase, depending on whether the activity called is in asynchronous mode) in PDF format.

Setting up a calling activity

On the process configuration page, select the process call task and then click on the “Choose Process” button.

Choose the called process from the suggested processes.

We would like to wait for the stock verification process to wait until the process called “Supply Purchase Request” is completed before proceeding (through the mail service in particular). Therefore, we do not activate the asynchronous/offset mode.

It is now necessary to configure the input variables that are transmitted to the called process (the variables that are in its start form) as well as the output variables (those that will be usable by the calling process).

The called process will then be able to use the values transmitted by the input variables and transmit its own variables to the calling process.

View of the configuration “Choice of inputs

We transmit the list of supplies created by the script, which are less than 100.

View of the configuration “Choice of outputs”.

Variables are selected that will be passed to the parent process by the child process.

Thus, the task that follows the calling activity, will be able to use the output variables in addition to its own variables.

Making a calling activity asynchronous

The Iterop functions: getParentProcessVariable and setParentProcessVariable work in Asynchronous mode, i.e. staggered, but can generate errors, especially if the parent process ends before the child process.

The peculiarity of an asynchronous calling activity is that it will not block the process until it is completed.
Therefore, no output data will be transmitted by the called process.
Indeed, we do not know when it will be able to transmit the output data. They would be unusable because it would cause errors to use variables that do not yet exist.

Activate asynchronous mode

To activate the asynchronous mode, go to Design, in the process configuration section. In the configuration of the Call-Activity task, on the selection page of the called process, you will find the “Asynchronous Mode” button at the bottom right of the process selection window :

Configuration of the process call.
Updated on 13 November 2020

Was this article helpful?

Related Articles

Need Support?
Can't find the answer you're looking for?
Contact Support