Fix worker queue fairness during backlog recovery #198
No reviewers
Labels
No labels
bug
dependencies
duplicate
enhancement
help wanted
invalid
javascript
question
symphony
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
backmeupplz/voicy!198
Loading…
Reference in a new issue
No description provided.
Delete branch "codex/VOI-71-worker-queue-fairness"
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
/jobs/claim-ready, with documented queue/recovery knobs and log context for scheduling buckets.Validation
yarn build-tsyarn test:worker-clientMONGO=mongodb://127.0.0.1:27018/voicy_voi71_worker_api yarn test:worker-apiusing temporarymongo:6Docker container; container stopped afterwardyarn lintManual QA
Required after deploy: while production backlog remains non-empty, send a fresh short Telegram voice and confirm the Windows worker claims/processes it promptly. Capture worker log lines showing
claimBucket/schedulingBucket; expected behavior is fresh/newest work appearing between older backlog jobs rather than waiting for the ready backlog to fully drain.Rework validation for VOI-71 after the task was reopened:
PR #198 is already merged and its CI/proof (test:worker-client) passes, but the merged scheduler does not cover the reopened production failure mode. The new production evidence is a fresh job that had already reached ready and then waited behind a large ready backlog.
The gap is in the merged scheduler:
So this PR should not close VOI-71. The follow-up fix needs explicit fair scheduling for already-ready jobs as well, e.g. alternate oldest/newest claim-ready buckets while backlog exists, and add a regression proof where two old ready jobs exist, a newer short ready job exists, and the newer job is selected before the old ready backlog drains. Live QA still needs a fresh Telegram voice while ready backlog remains non-empty.