pub enum RunnerState {
Idle,
Generating,
ExecutingTool,
PendingResumption {
config: Box<RealtimeConfig>,
bridge_message: Option<String>,
attempts: u8,
},
}realtime only.Expand description
Internal state machine tracking the resumability status of the RealtimeRunner.
Variants§
Idle
Runner is ready to accept transport resumption immediately.
Generating
Model is currently generating a response; tearing down the connection would corrupt context.
ExecutingTool
A tool is currently executing; teardown would cause tool loss.
PendingResumption
A context mutation was queued while the runner was busy, and must be executed once Idle.
Provider Context: This state is only utilized by providers that do not support
native mid-flight mutability (e.g., Gemini Live), requiring a physical transport teardown
and rebuild (Phantom Reconnect). Providers like OpenAI natively apply session.update
frames instantly and will never enter this queued state.
Queue Policy: The runner keeps only one pending resumption. If a new session update arrives while a resumption is already pending, the previous pending resumption is replaced. This is intentional: pending session updates represent desired end state, not an ordered command queue. The policy is last write wins.
Trait Implementations§
Source§impl Clone for RunnerState
impl Clone for RunnerState
Source§fn clone(&self) -> RunnerState
fn clone(&self) -> RunnerState
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for RunnerState
impl Debug for RunnerState
Source§impl Default for RunnerState
impl Default for RunnerState
Source§fn default() -> RunnerState
fn default() -> RunnerState
Source§impl PartialEq for RunnerState
impl PartialEq for RunnerState
Source§fn eq(&self, other: &RunnerState) -> bool
fn eq(&self, other: &RunnerState) -> bool
self and other values to be equal, and is used by ==.