prepare_session_deletion

Function prepare_session_deletion 

Source
pub async fn prepare_session_deletion(
    infra: &InfraContext<'_>,
    token: &str,
    session_name: &str,
    settings_group_name_opt: Option<&str>,
) -> Result<SessionDeletionContext, Error>
Expand description

Collect everything a session-delete operation will need, without mutating any state.

Validates group access first, then fans out four backend calls in parallel (groups, sessions, CFS components, BSS boot parameters) because each is independent and the latency dominates the operation. Returns NotFound when the named session isn’t in the (group-scoped) result set. The image ids the session produced are extracted up front so the apply step doesn’t need to re-derive them.