Mark project_ci_cd_settings.merge_trains_enabled for removal
requested to merge 12796-remove-merge_trains_enabled-column-from-project_ci_cd_settings-table into master
What does this MR do?
The merge_trains_enabled
column is no longer required. This MR will mark the project_ci_cd_settings.merge_trains_enabled for removal in the following release.
Please see the owning issue for more information.
Rows affected
There are an estimated 12,472,990 rows affected by this change on GitLab.com with an estimated 34 rows having merge_trains_enabled
set to TRUE
.
As such this migration can be done in three stages:
- mark the column as ignored and drop it (this MR)
- Drop the column
- remove the marked column directive in the following release
/chatops run explain SELECT * FROM project_ci_cd_settings;
Seq Scan on project_ci_cd_settings (cost=0.00..428901.90 rows=12472990 width=15) (actual time=1.025..3936.046 rows=11087036 loops=1)
Buffers: shared hit=34745 read=41298
I/O Timings: read=1703.218
Planning time: 0.621 ms
Execution time: 4552.465 ms
/chatops run explain SELECT * FROM project_ci_cd_settings where merge_trains_enabled is false;
Seq Scan on project_ci_cd_settings (cost=0.00..428901.90 rows=12472990 width=15) (actual time=0.009..1629.759 rows=11087011 loops=1)
Filter: (merge_trains_enabled IS FALSE)
Rows Removed by Filter: 34
Buffers: shared hit=76043
Does this MR meet the acceptance criteria?
Conformity
-
Changelog entry - [-] Documentation (if required)
-
Code review guidelines -
Merge request performance guidelines -
Style guides -
Database guides -
Separation of EE specific content
Availability and Testing
-
Review and add/update tests for this feature/bug. Consider all test levels. See the Test Planning Process. - [-] Tested in all supported browsers
Security
If this MR contains changes to processing or storing of credentials or tokens, authorization and authentication methods and other items described in the security review guidelines:
- [-] Label as security and @ mention
@gitlab-com/gl-security/appsec
- [-] The MR includes necessary changes to maintain consistency between UI, API, email, or other methods
- [-] Security reports checked/validated by a reviewer from the AppSec team
Part of #12796 (closed)
Edited by Sean Carroll