Setting the Agent Group for Workflows

The Agent Group Setting checkbox must be activated if you want workflow tasks that use the same agent group to use the same agents as well.

It can happen that different tasks inserted in a workflow are assigned to one and the same agent group. When processing them, the system checks whether the Agent Group Setting option is activated on the Attributes Pages of Executable Objects of the workflow definition:

XXX

Activating this checkbox causes the following workflow behavior:

  1. When the first task with an agent group is started, one of the agents in the group is assigned for processing it. This is a standard behavior.
  2. If you activate the Agent group Setting checkbox, the workflow stores both the information on the agent group and on the agent used for this task.
  3. As soon as the next task using the same agent group is started, the workflow retrieves this information and assigns the same agent to the task.

Storing the calculated agent groups in the top workflow ensures that all tasks, child workflows and task of child workflows use the same agent and that this agent is calculated only once.

In case of workflows within workflows, this setting must be activated in the parent. This option does not have this effect if selected in child workflows.

Take also into account that the agent group calculation is carried out when the task starts and not when it is activated. Therefore, the Generate Job at Runtime option refers to this point in time.

Re-using agent group calculation is not possible in:

Leaving this Option Deactivated

Agent group agents are retrieved for each individual task if this setting is not active. Therefore, tasks of the same agent group can run on different agents.

Example

The following graphics illustrate how this function works. In the following example, the Agent group Setting: Workflow tasks of the same Agent Group should use the same Agent checkbox has been activated in both workflows (Workflow1 and Workflow2).

The first task of the workflow (Job1) is processed first. It uses Agent group 1. Agent1 is selected because there are no internal entries for a former agent group calculation.

Subsequently, AgentGroup1 and the corresponding Agent1 are stored in the workflow.

Workflow2 is a child of the top workflow (Workflow1). Its task Job3 re-uses AgentGroup1. When Job3 starts, Agent1 (which has already been stored in the top workflow) is selected for the execution.

Therefore, all tasks of the same agent group use the same agent regardless of their subordination level. Note that this only applies to workflow tasks in which the option Re-using agent group calculation has been activated.

See also: