pub struct RequestedWorkerFacts {Show 15 fields
pub requested: Option<String>,
pub exists: bool,
pub admin_disabled: bool,
pub draining_or_drained: bool,
pub reachable: bool,
pub temporarily_bypassed: bool,
pub platform_matches: bool,
pub has_required_runtime: bool,
pub project_excluded: bool,
pub has_total_capacity: bool,
pub has_free_slots: bool,
pub estimated_cores: u32,
pub total_slots: u32,
pub admission_denial_code: Option<IncidentReasonCode>,
pub admission_denial_reason: Option<String>,
}Expand description
The facts an evaluator needs about an explicitly requested worker. The hook fills these from the daemon’s per-worker selection diagnostics; tests fill them directly.
Fields§
§requested: Option<String>The requested worker id (empty/none means “no request”).
exists: boolWhether the worker is a known, configured worker.
admin_disabled: boolOperator explicitly disabled this worker.
draining_or_drained: boolWorker is draining or drained (out of service by operator intent).
reachable: boolWorker is reachable / responding.
temporarily_bypassed: boolWorker is in transient quarantine (temporary bypass).
platform_matches: boolWorker OS/arch matches the build target.
has_required_runtime: boolWorker has the required runtime/toolchain/target.
project_excluded: boolWorker already runs this project (active-project exclusion).
has_total_capacity: boolWorker has enough configured total capacity for the request eventually.
has_free_slots: boolWorker has enough free slots for the request.
estimated_cores: u32Estimated core count for the request (the -j lever the reader can lower).
Retained so a capacity refusal can name the concrete numbers that collided
and the exact -j value that would fit (rch#35).
total_slots: u32The worker’s total configured slots (its hard capacity ceiling).
admission_denial_code: Option<IncidentReasonCode>Stable incident class for a remaining selector denial, if any.
admission_denial_reason: Option<String>Human-readable selector reason for a remaining admission denial.
Implementations§
Source§impl RequestedWorkerFacts
impl RequestedWorkerFacts
Sourcepub fn admissible(id: impl Into<String>) -> Self
pub fn admissible(id: impl Into<String>) -> Self
Facts for a fully admissible requested worker (test/clarity helper).
Sourcepub fn from_diagnostic(
requested: impl Into<String>,
worker: &WorkerSelectionDiagnostic,
) -> Self
pub fn from_diagnostic( requested: impl Into<String>, worker: &WorkerSelectionDiagnostic, ) -> Self
Build canonical requested-worker facts from daemon selection diagnostics.
Trait Implementations§
Source§impl Clone for RequestedWorkerFacts
impl Clone for RequestedWorkerFacts
Source§impl Debug for RequestedWorkerFacts
impl Debug for RequestedWorkerFacts
impl Eq for RequestedWorkerFacts
Source§impl PartialEq for RequestedWorkerFacts
impl PartialEq for RequestedWorkerFacts
impl StructuralPartialEq for RequestedWorkerFacts
Auto Trait Implementations§
impl Freeze for RequestedWorkerFacts
impl RefUnwindSafe for RequestedWorkerFacts
impl Send for RequestedWorkerFacts
impl Sync for RequestedWorkerFacts
impl Unpin for RequestedWorkerFacts
impl UnsafeUnpin for RequestedWorkerFacts
impl UnwindSafe for RequestedWorkerFacts
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.