pub struct SchedulerJson {
pub name: String,
pub manifest_dir: String,
pub binary_kind: BinaryKindJson,
pub topology: TopologyJson,
pub sched_args: Vec<String>,
pub sysctls: Vec<SysctlJson>,
pub kargs: Vec<String>,
pub cgroup_parent: Option<String>,
pub config_file: Option<String>,
pub kernels: Vec<String>,
pub verifier_exclude_topologies: Vec<String>,
pub constraints: TopologyConstraintsJson,
}Expand description
JSON shape projected from a registered Scheduler. Each entry
carries the complete execution identity needed to compare declarations:
scheduler name, a BinaryKindJson-tagged binary specification
(Discover / Path / Eevdf / KernelBuiltin), guest setup, static scheduler
configuration, per-scheduler default TopologyJson, always-on scheduler
args, declared kernel set, and gauntlet constraints. Assertion overrides
and inline per-test config-file content are intentionally omitted.
Fields§
§name: StringScheduler name — the name = "..." value supplied to
declare_scheduler! or
Scheduler::named.
manifest_dir: StringManifest directory of the crate that declared this scheduler.
Discover resolution is workspace-relative: cargo walks upward from
this directory to find the declaring workspace. The verifier parent
carries it through scheduler discovery so it can prebuild the exact
package once and key the immutable artifact manifest identically to
the child cell. The serde default keeps probes from older linked test
binaries readable during a rolling upgrade.
binary_kind: BinaryKindJsonBinary specification: distinguishes Discover (build via cargo
[[bin]] name), Path (use absolute path verbatim), Eevdf
(kernel default scheduler, no binary), and KernelBuiltin
(built into the kernel, enable/disable via guest commands).
The variant tag lets the verifier dispatch exhaustively match
on the binary type without parsing the string.
topology: TopologyJsonDefault VM topology for tests using this scheduler. The
verifier sweep’s per-cell topology comes from gauntlet presets
filtered through constraints; this field carries the
per-scheduler baseline that test-entry plumbing inherits when
a test does not override numa_nodes/llcs/cores/threads
in its #[ktstr_test] attributes. Mirror of
Scheduler::topology.
sched_args: Vec<String>Always-on scheduler CLI args.
sysctls: Vec<SysctlJson>Guest sysctls applied before scheduler startup, in declaration order.
This remains a sequence instead of a map because duplicate keys are meaningful: the last declared value wins.
kargs: Vec<String>Extra guest kernel command-line arguments.
cgroup_parent: Option<String>Optional scheduler cgroup parent path.
config_file: Option<String>Optional host-side static scheduler config-file path.
kernels: Vec<String>Kernel specs (consumed by cargo_ktstr::kernel::resolve_kernel_set).
verifier_exclude_topologies: Vec<String>Named topology presets excluded only from the verifier matrix.
constraints: TopologyConstraintsJsonGauntlet preset constraints (filter the verifier’s topology sweep).
Implementations§
Source§impl SchedulerJson
impl SchedulerJson
Sourcepub fn accepts_verifier_kernel(&self, label: &str, sanitized: &str) -> bool
pub fn accepts_verifier_kernel(&self, label: &str, sanitized: &str) -> bool
Whether one resolved kernel entry survives this scheduler’s declared
kernel filter. Shared by test-binary cell emission and the
cargo ktstr verifier parent prebuild planner so both sides classify
the same raw/sanitized label pair identically.
Sourcepub fn accepts_verifier_preset(&self, preset: &TopoPreset) -> bool
pub fn accepts_verifier_preset(&self, preset: &TopoPreset) -> bool
Whether one canned topology preset survives this scheduler’s verifier constraints and named verifier-only exclusions.
Sourcepub fn has_accepted_verifier_cell<'a>(
&self,
kernels: impl IntoIterator<Item = (&'a str, &'a str)>,
presets: &[TopoPreset],
) -> bool
pub fn has_accepted_verifier_cell<'a>( &self, kernels: impl IntoIterator<Item = (&'a str, &'a str)>, presets: &[TopoPreset], ) -> bool
Whether the resolved kernel × canned-preset matrix contains at least one cell this scheduler can emit. Binary-kind, path-existence, workspace-membership, and scheduler-name checks are intentionally handled by the callers because they require registry or filesystem context; the matrix policy itself stays pure and shared.
Sourcepub fn from_scheduler(s: &Scheduler) -> Self
pub fn from_scheduler(s: &Scheduler) -> Self
Project a Scheduler static into its JSON shape.
Trait Implementations§
Source§impl Clone for SchedulerJson
impl Clone for SchedulerJson
Source§fn clone(&self) -> SchedulerJson
fn clone(&self) -> SchedulerJson
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for SchedulerJson
impl Debug for SchedulerJson
Source§impl<'de> Deserialize<'de> for SchedulerJson
impl<'de> Deserialize<'de> for SchedulerJson
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Source§impl PartialEq for SchedulerJson
impl PartialEq for SchedulerJson
Source§impl Serialize for SchedulerJson
impl Serialize for SchedulerJson
impl Eq for SchedulerJson
impl StructuralPartialEq for SchedulerJson
Auto Trait Implementations§
impl Freeze for SchedulerJson
impl RefUnwindSafe for SchedulerJson
impl Send for SchedulerJson
impl Sync for SchedulerJson
impl Unpin for SchedulerJson
impl UnwindSafe for SchedulerJson
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,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more