Add ClaimQueue wrapper (#3950)

Remove `fetch_next_scheduled_on_core` in favor of new wrapper and
methods for accessing it.

---------

Signed-off-by: Andrei Sandu <andrei-mihail@parity.io>
This commit is contained in:
Andrei Sandu
2024-04-03 18:01:34 +03:00
committed by GitHub
parent ecc51a2535
commit 0f4e849e0a
5 changed files with 55 additions and 32 deletions
@@ -2163,8 +2163,8 @@ async fn determine_groups_per_para(
// pending availability.
let para_core_indices: Vec<_> = if let Some(claim_queue) = maybe_claim_queue {
claim_queue
.into_iter()
.filter_map(|(core_index, paras)| Some((*paras.front()?, core_index)))
.iter_claims_at_depth(0)
.map(|(core_index, para)| (para, core_index))
.collect()
} else {
availability_cores