Finding UUID Migration Phase 3: Add NOT NULL constraint to new_uuid
What does this MR do and why?
Implements Phase 3 of the Finding UUID migration (#587799).
Adds a NOT NULL constraint to the new_uuid column on vulnerability_occurrences after the Phase 2 backfill completes.
Changes
Uses the 3-step approach for large tables:
-
Add constraint without validation (
20260127164510)- Adds the constraint but doesn't validate existing rows (fast)
-
Prepare async validation (
20260127164526)- Schedules background validation of existing rows
-
Validate constraint (
20260127164542)- Final validation (fast because async already validated)
Dependencies
This MR targets the Phase 2 branch and cannot be merged until:
- Phase 1 (!220835 (merged)) merges
- Phase 2 (!220866) merges
Migration Plan
| Phase | Issue | MR | Status |
|---|---|---|---|
| 1 | #587625 (closed) | !220835 (merged) | In Review |
| 2 | #587798 | !220866 | Pipeline Running |
| 3 | #587799 | This MR | Ready for Review |
| 4 | #587800 | - | Not Started |
| 5 | #587801 | - | Not Started |
MR acceptance checklist
Please evaluate this MR against the MR acceptance checklist.
Closes #587799