Skip to main content

set_container_executor

Function set_container_executor 

Source
pub fn set_container_executor(exec: Arc<dyn ContainerBuildExecutor>)
Expand description

Register the process-global container build executor.

Idempotent: calling again replaces the current executor (tests swap in mocks this way). The runtime layer calls this once at startup; until it does, container_executor returns None and containerized build paths fail with crate::error::ToolchainError::ExecutorUnavailable.

Poison-tolerant: the guarded value is a plain pointer swap with no intermediate states, so a panic in another thread holding the lock cannot leave it torn — this recovers the inner value instead of propagating the poison.