pub struct PlanRuntimeResources<R>where
R: DeviceRuntime,{ /* private fields */ }Expand description
Unique plan-lifetime owner of the runtime, dynamic pools, maintenance authority, static buffers, capacity claims, and cleanup authority.
Implementations§
Source§impl<R> PlanRuntimeResources<R>where
R: DeviceRuntime,
impl<R> PlanRuntimeResources<R>where
R: DeviceRuntime,
pub fn deferred_cleanup_status(&self) -> DeferredDeviceCleanupStatus
pub fn create_execution_lane( &self, ) -> Result<Arc<ExecutionLane<R>>, ExecutionLaneCreationError<R::Error>>
Sourcepub fn maintain_deferred_cleanups(
&self,
maximum_tasks: usize,
) -> Result<DeferredDeviceCleanupMaintenanceReceipt, VNextError>
pub fn maintain_deferred_cleanups( &self, maximum_tasks: usize, ) -> Result<DeferredDeviceCleanupMaintenanceReceipt, VNextError>
Attempts each selected cleanup owner at most once. This may block in a backend recovery call and must therefore run on a scheduler recovery thread, never on a request, admission, or destructor path.
pub fn trusted_runtime_binding( self: &Arc<Self>, ) -> Result<TrustedPlanRuntimeBinding<R>, VNextError>
pub fn maintain_for_admission_deferred( self: &Arc<Self>, deferred: &AdmissionDeferred, ) -> Result<DynamicDeferredMaintenanceOutcome, VNextError>
Sourcepub fn try_maintain_for_capacity_pressure(
self: &Arc<Self>,
deferred: &AdmissionDeferred,
) -> Result<Option<DynamicPoolGrowthBatchReceipt>, VNextError>
pub fn try_maintain_for_capacity_pressure( self: &Arc<Self>, deferred: &AdmissionDeferred, ) -> Result<Option<DynamicPoolGrowthBatchReceipt>, VNextError>
Attempts currently needed foreground pool growth without reclaiming
other pools or increasing execution slots. None means a slot or
non-pool blocker is inapplicable. Any receipt, including an empty one,
requires a fresh admission probe; it does not reserve the free capacity.
Device/pool capacity errors remain typed so the caller can next apply
its existing cache-eviction or waiting policy.
Sourcepub fn dynamic_pool_status(
&self,
) -> Result<DynamicPoolMaintenanceStatus, VNextError>
pub fn dynamic_pool_status( &self, ) -> Result<DynamicPoolMaintenanceStatus, VNextError>
Returns a point-in-time view of the exact dynamic pools owned by this plan. Product telemetry consumes this instead of maintaining a second allocator ledger that can drift from admission decisions.
pub fn write_dynamic_capacity_availability( &self, out: &mut Vec<CapacityAvailabilityEpoch>, ) -> Result<CapacityEpochs, VNextError>
pub fn register_capacity_waiter( self: &Arc<Self>, observed: &CapacityWaitCondition, ) -> Result<PlanCapacityWaitRegistration<R>, VNextError>
pub fn is_closing(&self) -> bool
pub fn close( resources: Arc<Self>, ) -> Result<PlanRuntimeCloseOutcome<R>, PlanRuntimeCloseFailure<R>>
Source§impl<R: DeviceRuntime> PlanRuntimeResources<R>
impl<R: DeviceRuntime> PlanRuntimeResources<R>
Sourcepub fn try_maintain_checkpoint_with_idle_reclaim(
self: &Arc<Self>,
maintenance: CheckpointCapacityMaintenance<R>,
) -> Result<CheckpointCapacityMaintenanceOutcome, VNextError>
pub fn try_maintain_checkpoint_with_idle_reclaim( self: &Arc<Self>, maintenance: CheckpointCapacityMaintenance<R>, ) -> Result<CheckpointCapacityMaintenanceOutcome, VNextError>
Explicitly permits one idle-chunk reclaim attempt after ordinary checkpoint growth fails at the device budget. All capture target pools remain protected, as do committed occupancy and resident minima. This does not reserve capacity for future, unadmitted foreground work.
The owner must belong to this exact resource root. No sequence is evicted or waited on, and a Ready receipt still requires a fresh claim.