issues bigint batch 2: swap id and drop temporary objects
Everyone can contribute. Help move this issue forward while earning points, leveling up and collecting rewards.
Swap the issues.id column with its bigint counterpart, including the primary key, then drop the temporary objects left behind.
Tasks
- Swap migration: swap the 12 indexes, swap the column default for sequence ownership, swap the primary key (drop constraint with cascade, rename the bigint index, add primary key using index), and re-point the incoming foreign keys before the swap
- Drop temporary objects: drop the temporary foreign keys first (one migration each), then the 12 temporary indexes
- Capture swap transaction timings on a production clone
Dependencies
Order for batch 2:
- Create the bigint indexes — #629828
- Add the incoming foreign keys on
issues.id— #629829 - Swap
idand drop the temporary objects (this issue)
Both preceding issues must be complete first. The swap drops the primary key constraint with cascade, so every incoming foreign key must already be re-pointed at the bigint column and valid.
Foreign keys are dropped before indexes, because a live foreign key without a supporting index makes deletes from the referenced table time out.
The milestone may shift to 19.6 if the earlier batch 2 steps run long.
Edited by 🤖 GitLab Bot 🤖