Skip to content
Snippets Groups Projects
Unverified Commit 676bacd7 authored by Bastian Köcher's avatar Bastian Köcher Committed by GitHub
Browse files

Always schedule at least one job onto a core (#1990)

Even if the host configuration is returning `0` for the `lookahead`, we
should schedule at least one job on a core if the core exists.
parent 5ca909cc
No related merge requests found
Pipeline #404119 passed with stages
in 1 hour, 5 minutes, and 11 seconds
......@@ -627,8 +627,8 @@ impl<T: Config> Pallet<T> {
if ValidatorGroups::<T>::decode_len().map_or(true, |l| l == 0) {
return
}
let n_lookahead = Self::claimqueue_lookahead();
// If there exists a core, ensure we schedule at least one job onto it.
let n_lookahead = Self::claimqueue_lookahead().max(1);
let n_session_cores = T::AssignmentProvider::session_core_count();
let cq = ClaimQueue::<T>::get();
let ttl = <configuration::Pallet<T>>::config().on_demand_ttl;
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment