Rotate BReg authority work classes instead of returning after the first submission
Nobody has claimed this yet.
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 68/100
Research direction
Start in crates/registry-breg/src/review_store.rs at ReviewWorker::run_one and trace the authority work-class loops and their fixed ordering. Add or update the Postgres test described in the issue, and consider the work done when continuously ready submissions no longer prevent a pending cancellation and due result poll from making progress.
Written by the indexing model from the issue text.
Description
An automated review of #1189 flagged a fairness gap in the BReg review worker's authority pass. In crates/registry-breg/src/review_store.rs, run_one walks its work classes in a fixed order and returns Ok(true) as soon as one unit of work succeeds: submissions first, then cancellations, then the result feed, then result polls.
Failure scenario: pending submissions stay continuously ready, so every pass ends in the submissions loop and the cancellation and result loops below never run. ReviewWorker already stops application jobs from starving authority work, but sustained submission traffic can still starve accepted or cancelling reviews until their recovery or result-retention windows expire.
Suggested fix:
- Rotate the authority work classes across passes (round-robin or a per-class cursor) instead of always restarting at submissions.
- Add a Postgres test with continuously ready submissions that asserts a pending cancellation and a due result poll still make progress.
Filed from the review of #1189; not merge-blocking.
- Dominant language
- Rust
- Stars
- 2
- Forks
- 0
- Avg merge
- 3h 45m
- Merged PRs (30d)
- 134
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from registrystack/registry-stack
-
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
registrystack/registry-stack#1239 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
registrystack/registry-stack#1235 ·
-
area:breg bug good first issue rust
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
registrystack/registry-stack#1227 ·
-
area:casework documentation
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
registrystack/registry-stack#1217 ·
-
area:breg documentation
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
registrystack/registry-stack#1213 ·
All issues in registrystack/registry-stack
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
stratum-mining/stratum#2404 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 85/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
Eynzof/Hermes-CN-Desktop#610 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
-
bug team:backend track:services-maintenance
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
cowprotocol/services#4950 ·