Data Migration Wiki

This page is the living technical document for migration scope, decisions, limitations, and open tasks. Update it for every migration wave.

Scope

Source of Truth

Implemented Data Migrations

  1. 20260326_move_responsible_flight_rescuer_to_air_rescuer_profiles.sql
  2. 20260403_file_manager_file_lifecycle_phase1.sql
  3. 20260415_helicopter_import_apply.sql

Known Migration Decisions and Gaps

Confirmed "Will Not Migrate" (Current Decision)

  1. Legacy helicopter columns intentionally ignored:

    Decision is documented in migrations/scripts/migration_helicopter.sql.

Confirmed "Not Migrated Yet" (Open)

  1. Legacy SQS queue backlog
  2. Binary files (PDF/images) into new file manager storage
  3. Legacy photo_file_id references in contact profile tables

Manual Actions Required at Cutover

  1. Validate which legacy PDFs/images must remain accessible on day 1.
  2. For files without automated import, perform manual re-upload via file manager flow.
  3. Re-link uploaded files to business references (attachments) and to entity-level attachment columns where relevant.
  4. Obtain client sign-off for any files intentionally left unmigrated.

Migration TODO Register

ID Item Type Status Owner Notes
MIG-001 Decide final strategy for legacy PDFs/images: automated import vs manual re-upload Decision Open TBD Blocks final cutover checklist
MIG-002 Produce inventory of all legacy file references and classify critical/non-critical Analysis Open TBD Include PDFs + photos
MIG-003 If automation chosen, implement importer to populate file_files and attachments safely Engineering Open TBD Prefer idempotent batch import with audit log
MIG-004 Define mapping from legacy contact photo_file_id to new attachment model Engineering Open TBD Covers pilot/doctor/air rescuer/technician/FA/staff
MIG-005 Document and execute SQS backlog drain/discard plan before production cutover Ops Open TBD See queue migration doc
MIG-006 Create client-facing exception list for data that cannot/will not be migrated Governance Open TBD Must be approved before go-live

Cutover Validation Checklist

  1. Run DB migrations in target environment.
  2. Run all required data migration scripts (including helicopter import flow if applicable).
  3. Validate row counts and sample records for migrated domains.
  4. Validate file accessibility for mandatory records (especially PDFs needed operationally).
  5. Validate queue behavior post-cutover (pending to published, no legacy SQS dependency).
  6. Record migration result, exceptions, and follow-up tickets on this page.

Change Log