forked from 0xWheatyz/SPARC
feat(jobs): persist async batch job state in PostgreSQL #34
Reference in New Issue
Block a user
Delete Branch "feature/persist-job-state"
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?
Summary
jobstable to PostgreSQL schema for persisting async batch job stateDatabaseClientmethods:create_job,update_job,get_job,list_jobs,mark_stale_jobs_failed_run_batch_joband all job endpoints to read/write from the database_jobsdict -- job state now survives API restartsrunning/pendingstate are markedfailedto avoid stuck statesCloses #8
Test plan
/jobs/{job_id}still returns the jobrunningstate at restart are markedfailed/jobslist endpoint returns persisted jobs🤖 Generated with Claude Code
AI-Manager referenced this pull request from 0xWheatyz/SPARC2026-03-26 05:42:22 +00:00