jobs: queue scheduler + REST job API (phase 1c + 2)
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
@@ -63,7 +63,12 @@ Favor power-user affordances over guardrails. See memory `sole-user-assume-compe
|
||||
abort poll, returns exitCode), `process-tree.ts` (shared killTree), `pipeline-job-manager` now
|
||||
dispatches by `mode` and finalizes script jobs by exit code. *Compiles; runtime-untested until
|
||||
a REST caller + restart exist.*
|
||||
- [ ] 1c scheduler / queue (FIFO pending → promote on finalize; promoteNext on startup)
|
||||
- [ ] 2 REST job API + WS consolidation
|
||||
- [x] 1c scheduler / queue — `enqueueJob(action)` (start now / queue behind running), `promoteNext()`
|
||||
on finalize + startup, `getOldestPendingJob`, `markInterruptedJobs` now running-only (pending
|
||||
queue survives restart). `startJob` kept as a `enqueueJob(...,'start')` wrapper.
|
||||
- [x] 2 REST job API — `POST /jobs` (create script|pipeline, action start/queue), `GET /jobs` (+`?live=1`,
|
||||
now returns mode/exitCode/isLive), `GET /jobs/:id`, `GET /jobs/:id/log?offset=`, `POST /jobs/:id/stop`.
|
||||
Router mounted at `/jobs` and `/pipeline-jobs`. *Needs a restart to deploy; then curl/phone-testable.*
|
||||
WS consolidation still pending (old `/api/tasks/run/ws` + `/api/tasks/pipeline/ws` still live).
|
||||
- [ ] 3 /jobs/new page + JobDetail script branch + retire modal + header indicator
|
||||
- [ ] 4 push notifications
|
||||
|
||||
Reference in New Issue
Block a user