MCPcopy Create free account
hub / github.com/NVIDIA/OpenShell / handle_delete_sandbox

Function handle_delete_sandbox

crates/openshell-server/src/grpc/sandbox.rs:479–494  ·  view source on GitHub ↗
(
    state: &Arc<ServerState>,
    request: Request<DeleteSandboxRequest>,
)

Source from the content-addressed store, hash-verified

477}
478
479pub(super) async fn handle_delete_sandbox(
480 state: &Arc<ServerState>,
481 request: Request<DeleteSandboxRequest>,
482) -> Result<Response<DeleteSandboxResponse>, Status> {
483 let result = handle_delete_sandbox_inner(state, request).await;
484 let outcome = match &result {
485 Ok(response) if response.get_ref().deleted => TelemetryOutcome::Success,
486 _ => TelemetryOutcome::Failure,
487 };
488 openshell_core::telemetry::emit_lifecycle(
489 LifecycleResource::Sandbox,
490 LifecycleOperation::Delete,
491 outcome,
492 );
493 result
494}
495
496async fn handle_delete_sandbox_inner(
497 state: &Arc<ServerState>,

Callers 1

delete_sandboxMethod · 0.85

Calls 2

emit_lifecycleFunction · 0.85

Tested by

no test coverage detected