Skip to content

Draft: Prepare Pages deployment to Multiple Versions

What does this MR do and why?

Add PagesDeployment#deprecated field

Currently when a new PagesDeployment is created, we add its id to ProjectPagesMetadatum. This step is required as the new deployment might take a while to be uploaded to the Object Storage, therefore, instead of only replacing the current deployment for the project, we create a new one to avoid race conditions.

With the work to introduce Gitlab Pages Multiple Versions, a project now have to support multiple PagesDeployment at the same time. For this reason, instead of using ProjectPagesMetadatum#pages_deployment_id to identify valid deployment, we're introducing a PagesDeployment#deprecated field.

The PagesDeployment#deprecated is used to signalize when a new deployment for a project was created. In the near future it'll differentiate when a new deployment for a given project and path_prefix was created.

Changelog: changed

Screenshots or screen recordings

Screenshots are required for UI changes, and strongly recommended for all other merge requests.

Before After

How to set up and validate locally

Numbered steps to set up and validate the change are strongly suggested.

MR acceptance checklist

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

Merge request reports

Loading