forked from 0xWheatyz/SPARC
Persist async job state in PostgreSQL so results survive API restart #135
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Context
Batch job status is stored in an in-memory
_jobsdict. Any API restart wipes all job state, causing users to lose track of in-progress or completed batch results.Work
jobstable in PostgreSQL (or reuse an existing schema) to store job ID, status, created_at, updated_at, and result payload._jobsdict with database calls.Acceptance Criteria
GET /jobs/{job_id}still returns the correct status and result.jobstable cleanly on a fresh install.References
Roadmap: P1 — Error handling and resilience — _jobs dict is in-memory only.
Closing: Async job state is persisted in PostgreSQL with a jobs table. Resolved via PR #34.