forked from 0xWheatyz/SPARC
Persist async job state in PostgreSQL to survive API restarts #687
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
Roadmap item: P1 Error handling and resilience
The
_jobsdictionary is held in memory only. Every API restart discards all in-progress and completed job records, causing clients to receive 404s for jobs that were submitted before the restart.Work to do
jobstable (or equivalent) in PostgreSQL to store job id, status, created_at, updated_at, result, and error fieldsAcceptance criteria
Closing as already implemented. Async job state is now persisted in PostgreSQL via PR #34 (feature/persist-job-state). Jobs survive API restarts. See SPARC/database.py.