Skip to content

fix(metadata-db): backfill missing job descriptors in job_events#1983

Merged
Theodus merged 1 commit intomainfrom
theodus/migration
Mar 16, 2026
Merged

fix(metadata-db): backfill missing job descriptors in job_events#1983
Theodus merged 1 commit intomainfrom
theodus/migration

Conversation

@Theodus
Copy link
Member

@Theodus Theodus commented Mar 16, 2026

Corrective migration for jobs that were past SCHEDULED state when the job_events table was created, causing their descriptors to be lost.

  • Add migration to insert SCHEDULED events with descriptors from jobs.descriptor
  • Target jobs that have a non-null descriptor but no SCHEDULED event with detail
  • Use NOT EXISTS guard to make the migration idempotent for all deployment states

Corrective migration for jobs that were past `SCHEDULED` state when the
job_events table was created, causing their descriptors to be lost.
- Add migration to insert `SCHEDULED` events with descriptors from `jobs.descriptor`
- Target jobs that have a non-null descriptor but no `SCHEDULED` event with detail
- Use `NOT EXISTS` guard to make the migration idempotent for all deployment states
@Theodus Theodus requested review from LNSD and shiyasmohd March 16, 2026 21:42
@Theodus Theodus merged commit ffd3383 into main Mar 16, 2026
8 checks passed
@Theodus Theodus deleted the theodus/migration branch March 16, 2026 23:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants