Struct Admission

Source
pub struct Admission {
Show 17 fields pub enabled: bool, pub required: bool, pub quota_cmd: Option<String>, pub live_jobs_cmd: Option<String>, pub lock: Option<String>, pub lock_kind: String, pub reservations: Option<String>, pub margin: Option<u64>, pub unknown_reserve: Option<u64>, pub default_footprint: Option<u64>, pub job_id_env: String, pub quota_total: Option<u64>, pub footprints: Option<String>, pub line_overhead: Option<u64>, pub attempts: u32, pub wait_seconds: u64, pub max_wait_seconds: u64,
}
Expand description

Inode admission before a build unit starts.

Fields§

§enabled: bool

Set false to skip the phase.

§required: bool

When true, a missing quota_cmd or reservations refuses the run with exit 78. When false, the phase is skipped as not configured.

§quota_cmd: Option<String>

Shell command printing the quota JSON, passed to stack admit --quota-cmd.

§live_jobs_cmd: Option<String>

Shell command printing live job ids, passed to stack admit --live-jobs-cmd. Without it every other job’s reservation counts, including those of jobs that ended without removing theirs; check warns.

§lock: Option<String>

Lock file shared by all admission controllers; run also takes it to remove the job’s reservation.

§lock_kind: String

flock or posix; must match the other lock holders.

§reservations: Option<String>

Directory of reservations.

§margin: Option<u64>

Inodes kept free.

§unknown_reserve: Option<u64>

Inodes counted per live job that has no reservation record (stack admit --unknown-reserve).

§default_footprint: Option<u64>

Inode footprint of a unit when the shard plan gives none. Required when admission is enabled; check exits 2 without it.

§job_id_env: String

Environment variable that holds the scheduler job id at run time. run refuses with exit 78 before any build when it is unset or not a positive integer without a leading zero; plan shows ${NAME}.

§quota_total: Option<u64>

Planning cap, passed to stack shard --inode-quota.

§footprints: Option<String>

footprints.json for stack shard --inode-footprints.

§line_overhead: Option<u64>

Inodes per build list line beyond its build tree.

§attempts: u32

Admission attempts before the run is refused.

§wait_seconds: u64

Seconds before the second attempt; doubles on each further attempt.

§max_wait_seconds: u64

Upper bound of the wait between attempts.

Implementations§

Source§

impl Admission

Source

pub const FIELDS: &'static [FieldDoc]

The documentation of every key of this table, in declaration order.

Trait Implementations§

Source§

impl Clone for Admission

Source§

fn clone(&self) -> Admission

Returns a duplicate of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for Admission

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl<'de> Deserialize<'de> for Admission

Source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
Source§

impl PartialEq for Admission

Source§

fn eq(&self, other: &Admission) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 · Source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl Serialize for Admission

Source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
Source§

impl StructuralPartialEq for Admission

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<T> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,