Skip to main content

ExecutionManager

Trait ExecutionManager 

Source
pub trait ExecutionManager: Send + Sync {
Show 20 methods // Required methods fn inspect<'life0, 'life1, 'async_trait>( &'life0 self, execution_id: &'life1 ExecutionId, ) -> Pin<Box<dyn Future<Output = ExecutionManagerResult<ExecutionStatus>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait; fn pause<'life0, 'life1, 'async_trait>( &'life0 self, execution_id: &'life1 ExecutionId, generation: ExecutionGeneration, keep_memory: bool, ) -> Pin<Box<dyn Future<Output = ExecutionManagerResult<ExecutionLease>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait; fn resume<'life0, 'life1, 'async_trait>( &'life0 self, execution_id: &'life1 ExecutionId, generation: ExecutionGeneration, ) -> Pin<Box<dyn Future<Output = ExecutionManagerResult<ExecutionLease>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait; fn kill<'life0, 'life1, 'async_trait>( &'life0 self, execution_id: &'life1 ExecutionId, generation: ExecutionGeneration, ) -> Pin<Box<dyn Future<Output = ExecutionManagerResult<KillOutcome>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait; fn reconcile<'life0, 'life1, 'async_trait>( &'life0 self, operation_id: &'life1 OperationId, ) -> Pin<Box<dyn Future<Output = ExecutionManagerResult<ReconcileOutcome>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait; // Provided methods fn create<'life0, 'life1, 'async_trait>( &'life0 self, _request: CreateExecutionRequest, _operation_id: &'life1 OperationId, ) -> Pin<Box<dyn Future<Output = ExecutionManagerResult<ExecutionReservation>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait { ... } fn start<'life0, 'life1, 'async_trait>( &'life0 self, _execution_id: &'life1 ExecutionId, _generation: ExecutionGeneration, ) -> Pin<Box<dyn Future<Output = ExecutionManagerResult<ExecutionLease>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait { ... } fn create_and_start<'life0, 'life1, 'async_trait>( &'life0 self, request: CreateExecutionRequest, operation_id: &'life1 OperationId, ) -> Pin<Box<dyn Future<Output = ExecutionManagerResult<ExecutionLease>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait { ... } fn read_logs<'life0, 'life1, 'async_trait>( &'life0 self, _execution_id: &'life1 ExecutionId, _generation: ExecutionGeneration, ) -> Pin<Box<dyn Future<Output = ExecutionManagerResult<Vec<LogEntry>>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait { ... } fn list_processes<'life0, 'life1, 'async_trait>( &'life0 self, _execution_id: &'life1 ExecutionId, _generation: ExecutionGeneration, ) -> Pin<Box<dyn Future<Output = ExecutionManagerResult<ExecutionProcessInventory>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait { ... } fn stats<'life0, 'life1, 'async_trait>( &'life0 self, _execution_id: &'life1 ExecutionId, _generation: ExecutionGeneration, ) -> Pin<Box<dyn Future<Output = ExecutionManagerResult<ExecutionStats>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait { ... } fn events<'life0, 'life1, 'async_trait>( &'life0 self, _execution_id: &'life1 ExecutionId, _generation: ExecutionGeneration, _request: ExecutionEventsRequest, ) -> Pin<Box<dyn Future<Output = ExecutionManagerResult<ExecutionEventBatch>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait { ... } fn update_resources<'life0, 'life1, 'life2, 'async_trait>( &'life0 self, _execution_id: &'life1 ExecutionId, _generation: ExecutionGeneration, _operation_id: &'life2 OperationId, _update: ExecutionResourceUpdate, ) -> Pin<Box<dyn Future<Output = ExecutionManagerResult<ExecutionLease>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait { ... } fn create_filesystem_snapshot<'life0, 'life1, 'life2, 'async_trait>( &'life0 self, _execution_id: &'life1 ExecutionId, _generation: ExecutionGeneration, _snapshot_id: &'life2 ExecutionSnapshotId, ) -> Pin<Box<dyn Future<Output = ExecutionManagerResult<ExecutionSnapshot>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait { ... } fn filesystem_snapshot_size<'life0, 'life1, 'async_trait>( &'life0 self, _snapshot_id: &'life1 ExecutionSnapshotId, ) -> Pin<Box<dyn Future<Output = ExecutionManagerResult<Option<u64>>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait { ... } fn delete_filesystem_snapshot<'life0, 'life1, 'async_trait>( &'life0 self, _snapshot_id: &'life1 ExecutionSnapshotId, ) -> Pin<Box<dyn Future<Output = ExecutionManagerResult<bool>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait { ... } fn restart<'life0, 'life1, 'life2, 'async_trait>( &'life0 self, execution_id: &'life1 ExecutionId, generation: ExecutionGeneration, operation_id: &'life2 OperationId, ) -> Pin<Box<dyn Future<Output = ExecutionManagerResult<ExecutionLease>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait { ... } fn restart_with_options<'life0, 'life1, 'life2, 'async_trait>( &'life0 self, _execution_id: &'life1 ExecutionId, _generation: ExecutionGeneration, _operation_id: &'life2 OperationId, _options: RestartExecutionOptions, ) -> Pin<Box<dyn Future<Output = ExecutionManagerResult<ExecutionLease>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait { ... } fn kill_with_options<'life0, 'life1, 'async_trait>( &'life0 self, execution_id: &'life1 ExecutionId, generation: ExecutionGeneration, _options: KillExecutionOptions, ) -> Pin<Box<dyn Future<Output = ExecutionManagerResult<KillOutcome>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait { ... } fn remove<'life0, 'life1, 'async_trait>( &'life0 self, _execution_id: &'life1 ExecutionId, _generation: ExecutionGeneration, ) -> Pin<Box<dyn Future<Output = ExecutionManagerResult<bool>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait { ... }
}
Expand description

Backend-neutral lifecycle facade shared by the CLI, SDK, and remote service.

Required Methods§

Source

fn inspect<'life0, 'life1, 'async_trait>( &'life0 self, execution_id: &'life1 ExecutionId, ) -> Pin<Box<dyn Future<Output = ExecutionManagerResult<ExecutionStatus>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Source

fn pause<'life0, 'life1, 'async_trait>( &'life0 self, execution_id: &'life1 ExecutionId, generation: ExecutionGeneration, keep_memory: bool, ) -> Pin<Box<dyn Future<Output = ExecutionManagerResult<ExecutionLease>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Pause one execution and return the generation-fenced paused lease.

Source

fn resume<'life0, 'life1, 'async_trait>( &'life0 self, execution_id: &'life1 ExecutionId, generation: ExecutionGeneration, ) -> Pin<Box<dyn Future<Output = ExecutionManagerResult<ExecutionLease>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Source

fn kill<'life0, 'life1, 'async_trait>( &'life0 self, execution_id: &'life1 ExecutionId, generation: ExecutionGeneration, ) -> Pin<Box<dyn Future<Output = ExecutionManagerResult<KillOutcome>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Source

fn reconcile<'life0, 'life1, 'async_trait>( &'life0 self, operation_id: &'life1 OperationId, ) -> Pin<Box<dyn Future<Output = ExecutionManagerResult<ReconcileOutcome>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Provided Methods§

Source

fn create<'life0, 'life1, 'async_trait>( &'life0 self, _request: CreateExecutionRequest, _operation_id: &'life1 OperationId, ) -> Pin<Box<dyn Future<Output = ExecutionManagerResult<ExecutionReservation>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Persist exactly one unstarted execution reservation for operation_id.

Source

fn start<'life0, 'life1, 'async_trait>( &'life0 self, _execution_id: &'life1 ExecutionId, _generation: ExecutionGeneration, ) -> Pin<Box<dyn Future<Output = ExecutionManagerResult<ExecutionLease>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Start one created execution after fencing stale callers by generation.

Source

fn create_and_start<'life0, 'life1, 'async_trait>( &'life0 self, request: CreateExecutionRequest, operation_id: &'life1 OperationId, ) -> Pin<Box<dyn Future<Output = ExecutionManagerResult<ExecutionLease>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Create and start exactly one execution for operation_id.

Retrying after a crash reuses the durable reservation and continues its start instead of allocating a second execution.

Source

fn read_logs<'life0, 'life1, 'async_trait>( &'life0 self, _execution_id: &'life1 ExecutionId, _generation: ExecutionGeneration, ) -> Pin<Box<dyn Future<Output = ExecutionManagerResult<Vec<LogEntry>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Read structured stdout/stderr entries after fencing the runtime generation.

Source

fn list_processes<'life0, 'life1, 'async_trait>( &'life0 self, _execution_id: &'life1 ExecutionId, _generation: ExecutionGeneration, ) -> Pin<Box<dyn Future<Output = ExecutionManagerResult<ExecutionProcessInventory>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Return the runtime-visible init and live exec processes for one exact generation.

Source

fn stats<'life0, 'life1, 'async_trait>( &'life0 self, _execution_id: &'life1 ExecutionId, _generation: ExecutionGeneration, ) -> Pin<Box<dyn Future<Output = ExecutionManagerResult<ExecutionStats>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Return one normalized resource snapshot for an exact generation.

Source

fn events<'life0, 'life1, 'async_trait>( &'life0 self, _execution_id: &'life1 ExecutionId, _generation: ExecutionGeneration, _request: ExecutionEventsRequest, ) -> Pin<Box<dyn Future<Output = ExecutionManagerResult<ExecutionEventBatch>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Poll ordered runtime events without crossing the selected generation.

Source

fn update_resources<'life0, 'life1, 'life2, 'async_trait>( &'life0 self, _execution_id: &'life1 ExecutionId, _generation: ExecutionGeneration, _operation_id: &'life2 OperationId, _update: ExecutionResourceUpdate, ) -> Pin<Box<dyn Future<Output = ExecutionManagerResult<ExecutionLease>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait,

Apply a replay-safe partial live resource update to one exact generation.

Source

fn create_filesystem_snapshot<'life0, 'life1, 'life2, 'async_trait>( &'life0 self, _execution_id: &'life1 ExecutionId, _generation: ExecutionGeneration, _snapshot_id: &'life2 ExecutionSnapshotId, ) -> Pin<Box<dyn Future<Output = ExecutionManagerResult<ExecutionSnapshot>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait,

Temporarily quiesce the execution, atomically capture its rootfs in the runtime-managed snapshot store, and restore its prior stable state.

Source

fn filesystem_snapshot_size<'life0, 'life1, 'async_trait>( &'life0 self, _snapshot_id: &'life1 ExecutionSnapshotId, ) -> Pin<Box<dyn Future<Output = ExecutionManagerResult<Option<u64>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Return the size of a fully published runtime-managed snapshot, or None when it does not exist.

Source

fn delete_filesystem_snapshot<'life0, 'life1, 'async_trait>( &'life0 self, _snapshot_id: &'life1 ExecutionSnapshotId, ) -> Pin<Box<dyn Future<Output = ExecutionManagerResult<bool>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Delete a runtime-managed snapshot, refusing while an active execution still uses it as a copy-on-write lower.

Source

fn restart<'life0, 'life1, 'life2, 'async_trait>( &'life0 self, execution_id: &'life1 ExecutionId, generation: ExecutionGeneration, operation_id: &'life2 OperationId, ) -> Pin<Box<dyn Future<Output = ExecutionManagerResult<ExecutionLease>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait,

Terminate the current runtime, advance its generation exactly once, and start it again under an idempotent operation identity.

Source

fn restart_with_options<'life0, 'life1, 'life2, 'async_trait>( &'life0 self, _execution_id: &'life1 ExecutionId, _generation: ExecutionGeneration, _operation_id: &'life2 OperationId, _options: RestartExecutionOptions, ) -> Pin<Box<dyn Future<Output = ExecutionManagerResult<ExecutionLease>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait,

Restart with controls that become part of the durable operation intent.

Source

fn kill_with_options<'life0, 'life1, 'async_trait>( &'life0 self, execution_id: &'life1 ExecutionId, generation: ExecutionGeneration, _options: KillExecutionOptions, ) -> Pin<Box<dyn Future<Output = ExecutionManagerResult<KillOutcome>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Terminate one execution with controls that survive lifecycle recovery.

Managers without option-aware termination may delegate to Self::kill.

Source

fn remove<'life0, 'life1, 'async_trait>( &'life0 self, _execution_id: &'life1 ExecutionId, _generation: ExecutionGeneration, ) -> Pin<Box<dyn Future<Output = ExecutionManagerResult<bool>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Remove one terminal execution and all runtime-owned resources.

Implementations must fence removal by generation and make retries idempotent. Active executions must be stopped explicitly before this operation; removal must never imply an unrequested kill.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§