Skip to main content

SchedulerState

Struct SchedulerState 

Source
pub struct SchedulerState {
Show 17 fields pub run_spec: Option<LogicalAgentSpec>, pub advertised_tool_ids: Option<Vec<String>>, pub turn: u32, pub total_tokens: WireU64, pub rounds_completed: u32, pub subagents_spawned: u32, pub started_at_ms: Option<WireU64>, pub wall_budget_ms: Option<WireU64>, pub tasks: Vec<TaskControlState>, pub attempts: Vec<TaskAttemptState>, pub workflow: Option<WorkflowGraphState>, pub queued_signals: Vec<QueuedSignalState>, pub signal_dedupe_keys: Vec<String>, pub milestone: Option<MilestoneState>, pub entropy: EntropyState, pub channels: Vec<LocalChannelState>, pub objects: Vec<ObjectDescriptor>,
}
Expand description

§12.1 · the P2 plane: task control blocks and their attempts, budgets and waits, the workflow graph, queued signals plus dedupe memory, and the milestone cascade.

Fields§

§run_spec: Option<LogicalAgentSpec>

The active agent’s logical run contract. Required even when absent so checkpoints from the retired shape cannot be mistaken for current state.

§advertised_tool_ids: Option<Vec<String>>

Exact task-tool surface advertised by the most recent provider call. None means no provider call has been emitted yet and is fail-closed, not permissive.

§turn: u32§total_tokens: WireU64§rounds_completed: u32§subagents_spawned: u32§started_at_ms: Option<WireU64>

First observed clock of the run, the anchor the wall-budget axis measures against.

§wall_budget_ms: Option<WireU64>

§13.2 · the wall-clock budget an UpdateDeadline command last projected onto the axis. Not derivable from the configuration — the command sets a duration measured from Self::started_at_ms — so a restore that dropped it would un-bound the run.

§tasks: Vec<TaskControlState>

The task table. The home of task lifecycle and, with Self::attempts, of task identity.

§attempts: Vec<TaskAttemptState>

§10.4 · the attempt the kernel minted for each live task. A completion naming an attempt that is not here has no authority, which is why the mapping is checkpointed rather than re-derived from task ids.

§workflow: Option<WorkflowGraphState>§queued_signals: Vec<QueuedSignalState>§signal_dedupe_keys: Vec<String>

Router dedupe keys in eviction order, including keys for already-dispatched signals.

§milestone: Option<MilestoneState>§entropy: EntropyState

Session-disorder measurement and alert-gate state. These values intentionally survive a canonical crash restore even though they do not participate in a same-process turn rollback: otherwise the first post-restore sample forgets prior failures and rollbacks.

§channels: Vec<LocalChannelState>

Durable local fan-out channels, including per-consumer cursors and dedupe memory.

§objects: Vec<ObjectDescriptor>

Handle-only local object registry; bodies remain in context/payload storage.

Trait Implementations§

Source§

impl Clone for SchedulerState

Source§

fn clone(&self) -> SchedulerState

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

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

Performs copy-assignment from source. Read more
Source§

impl Debug for SchedulerState

Source§

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

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

impl Default for SchedulerState

Source§

fn default() -> SchedulerState

Returns the “default value” for a type. Read more
Source§

impl<'de> Deserialize<'de> for SchedulerState

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 SchedulerState

Source§

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

Equality operator ==. Read more
1.0.0 (const: unstable) · Source§

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

Inequality operator !=. Read more
Source§

impl Serialize for SchedulerState

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 SchedulerState

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> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,

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> Same for T

Source§

type Output = T

Should always be Self
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 = !

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

fn try_from(value: U) -> Result<T, !>

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.