Skip to content

Move CreateDeployments out of the pipeline creation critical path

What does this MR do and why?

Currently Pipeline::Chain::CreateDeployments is being called synchronously in CreatePipelineService. To reduce the total amount of time it takes this service to finish, we can move the step CreateDeployments to a background worker.

More details in the issue, but tldr moving to InitialPipelineProcessWorker should not affect the flow of execution and is a good short term remediation.

Screenshots or screen recordings

No additional changes. Deployments should still work.

Screenshot_2023-01-03_at_2.36.34_PM

How to set up and validate locally

  1. Ensure FF move_create_deployments_to_worker is enabled
  2. Create a pipeline with a deployment step that includes an environment
  3. Verify deployment get created

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Related to #383600 (closed)

Edited by Max Fan

Merge request reports