Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CDS-40448-run-stages-in-parallel #802

Merged
merged 6 commits into from
Mar 8, 2023
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Apply suggestions from code review
Co-authored-by: Michael Cretzman <58786311+michaelcretzman@users.noreply.github.com>
  • Loading branch information
roshnisarangadharan and michaelcretzman authored Mar 8, 2023
commit 667a6f9f50583f399aaf5fede9cd587e48af342c
17 changes: 11 additions & 6 deletions docs/platform/8_Pipelines/run-stages-in-parallel.md
Original file line number Diff line number Diff line change
@@ -1,17 +1,22 @@
---
title: Run Stages in Parallel
description: Run stages in parallel if you want to deploy multiple, independent services to the same environment.
title: Run CD stages in parallel
description: Perform parallel stage executions.
sidebar_position: 3
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this setting determines where the topic sits in the left navigation. Be sure to pick a spot that matches the importance of the topic.

---

Run stages in parallel when you want to deploy multiple services to the same environment.
You can run stages in parallel when you want to perform parallel operations. For example:

### Requirements
- CI: Parallel execution of builds and tests can speed up the integration process and provide faster feedback to developers.
- CD: Parallel execution of deployment stages can help reduce deployment times and increase the efficiency of the process.
- Infrastructure as Code (IaC): Parallel execution of IaC scripts can speed up the creation of resources and improve the scalability of infrastructure.
- Testing: Parallel execution of tests can reduce the overall testing time and provide faster feedback to developers.

## Requirements

* [Learn Harness' Key Concepts](../../getting-started/learn-harness-key-concepts.md)
* [Add a Stage](add-a-stage.md)

### Running stages in parallel
## Running stages in parallel

Run stages in parallel by dragging them together or by selecting the `+` button under a stage in the UI.

Expand All @@ -31,5 +36,5 @@ Navigate between the stages by hovering over them and selecting the stage.

A [Resource Constraint](../../continuous-delivery/cd-deployments-category/deployment-resource-constraints.md) step is added to every stage automatically to make sure that two infrastructures are not being deployed concurrently. Hence, one of the two parallel stages will deploy first. Once the deployment of the winning stage finishes, the other stages will start.

You can deploy multiple services and multiple environments in a single stage. However, using multi-service will deploy each selected service to a selected environment. For such use cases, we recommend using multiple stages.
You can deploy multiple services to multiple environments in a single stage (for more information, go to [Use multiple services and environments in a deployment](https://developer.harness.io/docs/continuous-delivery/cd-deployments-category/multiserv-multienv/)). However, running multi-service stages in parallel will deploy each service to each environment in parallel. This can become very complicated. For such use cases, we recommend using multiple stages.