Phase 7: Promotion of the CI database
## **Last async update:** https://gitlab.com/groups/gitlab-org/-/epics/7791#note_1013904772 ### Summary Following the completion of blocking development work in Phases 1-6, we need to rollout decomposition in production. This epic contains all tasks that are required to rollout decomposition in staging and production. #### High-level Execution plan 1. Adopt the DB upgrade runbooks and take downtime 1. During the failover focus on preventing and detecting any known issues 1. If we encounter issues during failover, roll back to Phase 4 1. If we encounter unknowns later, roll forward. ### Proposed timeline The overall timeline is located in https://gitlab.com/groups/gitlab-org/-/epics/6160#2022-timeline this epic contains details for Phase 7 ```mermaid gantt dateFormat YYYY-MM-DD title 90% confidence timeline section Phase 7 Block CI writes via triggers :done, rake, 2022-05-06, 2022-05-18 Multi-database Migrations[2.0] :done, rake, 2022-05-06, 2022-05-27 Create QA tests :done , Qa, 2022-05-06, 2022-05-30 Implement rollback strategy :done , infradb, 2022-05-06, 2022-06-08 [STG] Dry run plan preparation :done, dryrun, 2022-05-09, 2022-05-23 [STG] Run 1 - Dry run on staging :milestone, 2022-05-17, 0d [STG] Run 2 - Dry run on staging :milestone, 2022-05-23, 0d [PRD] Announce downtime for PRD :milestone, 2022-06-02, 0d [STG] Update Phase 7 execution plan :done , fks, 2022-05-23, 2022-06-13 [STG] Run 3 - Plan approved :milestone, 2022-05-30, 0d [STG] Run 3 - CI Decomposition execution with rollback | :milestone, 2022-05-30, 0d [TEST] Run 1 - CI Decomposition execution with rollback to CI1 :milestone, 2022-06-06, 0d [STG] Run 4 - CI Decomposition execution with rollback to Main :milestone, 2022-06-07, 0d [STG] Run 4 - Restore to `patroni-ci` read-only :milestone, 2022-06-07, 0d [STG] Run 5 - CI Decomposition execution with rollback to CI1 :milestone, 2022-06-08, 0d [STG] Run 5 - Restore to `patroni-ci` read-only :milestone, 2022-06-09, 0d [STG] Run 6 - CI Decomposition execution with rollback to CI1 :milestone, 2022-06-14, 0d [STG] Run 6 - Restore to `patroni-ci` read-only :milestone, 2022-06-15, 0d [STG] Run 7 - CI Decomposition execution :milestone, 2022-06-16, 0d [STG] Run 8 - CI Decomposition execution :milestone, 2022-06-17, 0d [STG] Monitor Phase 7 in staging :active , fks, 2022-06-17, 2022-07-02 [PRD] Finalize and peer review Phase 7 execution plan :done , fks, 2022-06-13, 2022-06-21 [PRD] Run 1 - CI Decomposition plan approved by leadership :milestone, 2022-06-21, 0d [PRD] Run 1 - CI Decomposition GO/NO GO meeting :milestone, 2022-06-30, 0d [PRD] Run 1 - CI Decomposition execution :milestone, 2022-07-02, 0d axisFormat %b-%d ``` ### Milestones | Milestone | Date | Status | | ------ | ------ | ------ | | [STG] [Run 1 - Dry run on staging](https://gitlab.com/gitlab-org/gitlab/-/issues/361762) | 2022-05-17 | Complete | [STG] [Run 2 - Dry run on staging](https://gitlab.com/gitlab-com/gl-infra/production/-/issues/7100) | 2022-05-23 | Complete | | [STG] Run 3 - Plan approved | 2022-05-31 | Complete | | [STG] Run 3 - CI Decomposition execution with rollback | 2022-05-31 | Complete | | [PRD] Announce downtime for PRD | 2022-06-02 | Complete | | [TEST] Run 1 - CI Decomposition execution with rollback to CI1 | 2022-06-06 | Complete | | [STG] Run 4 - [CI Decomposition execution with rollback to Main](https://ops.gitlab.net/gitlab-com/gl-infra/db-migration/-/issues/33) | 2022-06-07 | Complete | | [STG] Run 4 - [Restore to `patroni-ci` read-only](https://gitlab.com/gitlab-com/gl-infra/production/-/issues/7200) | 2022-06-07 | Complete | | [STG] Run 5 - [CI Decomposition execution with rollback to CI1](https://ops.gitlab.net/gitlab-com/gl-infra/db-migration/-/issues/37) | 2022-06-08 | Complete | | [STG] Run 5 - [Restore to `patroni-ci` read-only](https://gitlab.com/gitlab-com/gl-infra/production/-/issues/7201) | 2022-06-09 | [Complete](https://gitlab.com/gitlab-com/gl-infra/production/-/issues/7226) | | [STG] Run 6 - [CI Decomposition execution with rollback to CI1](https://ops.gitlab.net/gitlab-com/gl-infra/db-migration/-/issues/38) | 2022-06-14 | Complete | | [STG] Run 6 - [Restore to `patroni-ci` read-only](https://gitlab.com/gitlab-com/gl-infra/production/-/issues/7226) | 2022-06-15 |Complete | | [STG] Run 7 - [CI Decomposition execution with rollback to `main`](https://ops.gitlab.net/gitlab-com/gl-infra/db-migration/-/issues/34) | 2022-06-16 | Complete | | [STG] Run 8 - [CI Decomposition execution](https://ops.gitlab.net/gitlab-com/gl-infra/db-migration/-/issues/40) | 2022-06-17 | Complete | | [PRD] Run 1 - CI Decomposition plan approved by leadership | 2022-06-21| Complete | | [PRD] Run 1 - CI Decomposition GO/NO GO meeting | 2022-06-30 | [Complete](https://gitlab.com/gitlab-org/gitlab/-/issues/366586)| | [[PRD] Run 1 - CI Decomposition execution](https://gitlab.com/gitlab-com/gl-infra/production/-/issues/7111) | 2022-07-02 | Complete | ### Endstate ![phase_6__corrected_](/uploads/b961aa27ec1ce0f96898a90beb0a0b78/phase_6__corrected_.png)
epic