Convert ci_sources_pipelines.source_job_id to bigint - Step 2: Finalize background migrations and swap columns
With #328435 (closed) we have started the process of converting the foreign key from ci_sources_pipelines
that references ci_builds
(ci_sources_pipelines.source_job_id
) to bigint
(int8
).
In this issue we'll address the second step of the process:
-
Clean up the background migrations
-
Concurrently add any secondary indexes that include the
source_job_id
column"index_ci_sources_pipelines_on_source_job_id" btree (source_job_id)
-
Single Transaction: Drop old FK, define new FK (as invalid), swap columns, validate FK
Edited by Yannis Roussos