Skip to main content
Version: Release 24.1

Sequential Tasks With Parallel Groups

This topic explores how to configure sequential tasks with parallel groups in Release, allowing you to organize tasks that run sequentially within parallel execution groups.

With the parallel group task type you can execute tasks in parallel, instead of in sequence. By using dependencies among tasks, it is possible to "chain" some or all of the tasks in a parallel group in a sequence.

note

The sequential group task type can be use to group tasks that should be executed in order.

Execute tasks using multiple parallel groups

This example shows how Release can execute deployments to multiple servers in parallel, with the tasks on each server executing sequentially.

In the "Deploy" phase below, there is an outer parallel group called "Concurrent Server Deployments", which groups the tasks for the server. There are two sequential tasks per server: "Deploy code" and "Check results".

Parallel setup

In this setup, the default behavior of the "Server 1" and "Server 2" parallel groups is to run the "Deploy code" and "Check results" tasks in parallel. To change this so that the tasks execute sequentially, switch to the planner view.

Planner view

You can link the tasks to ensure they execute sequentially.

Linking tasks

Both server deployment blocks execute in parallel, but the tasks within each deployment are sequential:

Sequential tasks

Execute tasks using a single parallel group

The intermediate parallel groups "Server 1" and "Server 2" are not required as shown above. The same result can be achieved with a single parallel group. In the release flow:

Single parallel group

In the planner:

Single parallel group in planner view

This approach saves one level of nesting of parallel groups. It loses some visibility into the logical grouping of tasks for "Server 1" and "Server 2". Example: You can no longer collapse only the tasks for "Server 1". The approach with multiple parallel groups is recommended.