Skip to main content
Org syncing with Pipelines

Getting your features back-propagated through your Pipeline into the lower, long-lived (static), environments and Dev Sandboxes.

Mateusz Kochanowicz avatar
Written by Mateusz Kochanowicz
Updated over 2 months ago

Note: For customers migrating from the legacy workflow for synchronizing developer sandboxes using static environments, read below article first to find out how to make the move:
Migrating from legacy back propagation to Developer Sandbox Updates

This article explains how to get your features back-propagated through your Gearset Pipeline into the lower (static) environments.

By lower environments we mean specifically your long-lived Git branches, which are the source environments of your CI jobs - in the context of Gearset Pipelines.

Why is back propagation needed in Pipeline workflows?

Salesforce environments constantly change as you build features, deploy them, and release them to your production org.

Sometimes a hotfix is what you need to release quickly, and skipping parts of the release pipeline is needed. Over time, more and more metadata differences between your environments begin to appear.

Being able to back propagate (or back promote) features eases the task of aligning changes across all environments. And, most importantly, it allows developers to work from the most relevant code.

Ultimately, it leads to encouraging more frequent releases and reduces the likelihood of experiencing environment drift and overwriting work.

In promoting your first features article we guide you on how to forward propagate your changes with our Pipelines solution.

Let’s now look at how you can get your orgs synced and automatically make merged changes available for promotion to lower environments in the Pipeline.

The logic is simple: Gearset allows you to forward and back propagate, automatically creating (but not promoting) PRs on your behalf.

The way you can do this depends on what you’re trying to achieve. Before you go ahead, consider the steps we describe below.

Where do I want changes to be back propagated to?

Sync lower static environments (except Developer Sandboxes)

If your team does hotfixes and needs to get them back propagated to other (lower) Pipeline environments, but doesn't necessarily need to refresh metadata in Dev Sandboxes, then a setup similar to Pipeline shown below would be needed.

The tool automatically back propagates changes if they were to be merged straight into higher environments.

Example: A new PR opened from Hotfix environment, and promoted through the Pipeline by merging it into Main, would automatically create back propagation PRs into lower static environments (highlighted in green) - in this case UAT and INT.

If a PR is merged directly into Main branch (i.e. outside the Pipeline), it would also back propagate this change into UAT and INT (again only the static environments highlighted in green).

Recommended back propagation set up for your Pipeline

The recommended back propagation set up is to configure the Gearset Pipeline to create back propagation pull requests Only when changes are promoted into the final environment.

Click the cog icon: on the Pipelines UI page to find this setting.

A short video to show this option in Edit pipeline settings:

Sync lower environments (including Developer Sandboxes)

Make sure to read through our article on how the Dev Sandbox Updates feature works, and how to start using it within your Pipeline:
Getting started with Developer Sandbox Updates in Pipelines

Gearset allows you to enable updates directly to your Dev Sandboxes. This way you can back propagate (or back promote) changes directly to your Pipeline's Sandboxes.

You can decide which Sandbox in the pipeline to enable updates for. To do it, simply click on a given Sandbox and then select the three dots icon:- you'll then see a dropdown menu with Enable updates option.

A short video to demonstrate the setting:

Important to note: We strongly recommend to use Dev Updates feature with your Pipeline settings being configured to create back propagation pull requests only when changes are promoted into the final environment (see below photo).

What does the option "Only when changes are promoted to final environment" mean?

Configuring your Pipeline this way means that if you promote changes from one Dev Sandbox into to next environment in the Pipeline (e.g. INT), or in fact into any further static environment in the Pipeline (e.g. UAT), you are not yet triggering back propagation of the changes to any lower static environment.

This is simply because the changes begin to be back propagated to lower static environments only after being merged in Main/Master branch (and released in Production).

This is because a best practice and our recommendation is that you aim to have these changes tested and merged into Prod before they're being back propagated.

Why?

Because the risk of not doing this lies in the fact that any changes not yet promoted all the way through to Production could still change as the result of testing.

Therefore, building other work on top wouldn't be a solid foundation vs what's available live to end users.

What's the default behaviour?

  • Back propagation initiates after a PR is merged into the Master branch in your Pipeline.

  • That's when automatic PRs are opened simultaneously against any lower environments in the Pipeline (the environments highlighted in green).

Note: Back propagation PRs are opened only against lower environments that don't yet have the changes that were merged into the Main/Master branch.

Back propagation PRs are not automatically merged into the lower environments - this is a manual step that you need to take by selecting Promote changes button.

What does the option "When changes are promoted into any adjacent environment" mean?

Note: This is not a recommended setting for your Pipeline, as it only applies in Gearset's legacy back-propagation workflow for synchronizing Dev Sandboxes - as described with more details in this article.

In the context of Legacy back-propagation workflow, this options means that if you promote changes from any Developer Sandbox into the next environment in the Pipeline (e.g. INT), the back propagation to other Sandboxes in the Pipeline will be initiated.

How to configure this setting when I'm using Dev Sandbox updates in the Pipeline?


If you're using Dev Sandbox Updates feature, this Pipeline setting "Create back propagation pull requests" should always be configured to: "Only when changes are promoted into the final environment".

Things to remember

Remember that back propagation happens only to the static environments or Dev Sandboxes that don't yet contain the promoted changes.

Note: When we refer to "back propagation" in the context of Dev Sandboxes, we mean Gearset's new Dev Updates functionality.

More info on this feature in our documentation on:
Getting started with Developer Sandbox Updates in Pipelines

How to keep your environment (long-lived) branches in sync in Pipelines

If you're looking for information on how to keep your environment branches in sync, we have separate documentation that covers it in more detail:

Did this answer your question?