Skip to content
docsv0.34.0

StackComponent

The Stack section as a Milpa Component: its state is every backing service the booted plugins declared they need, with the state the panel observed for each. Image, ports, environment (secrets masked), volumes, command, the declaring plugin, the compose fragment and whether the probe port answers — read-only. Declaring a service is a plugin's job (`StackProviderInterface`); running it is the operator's; the panel shows what was declared, by whom, and whether it is reachable.

StackComponent::__construct()

public function __construct(Milpa\Runtime\Stack\StackReader $source):

Parameters

Parameters of __construct()
NameTypeDescription
$sourceMilpa\Runtime\Stack\StackReader

StackComponent::contract()

public static function contract(): Milpa\Live\ValueObjects\ComponentContract

The contract: no props, a read-only state, no actions.

StackComponent::mount()

public function mount(array $props, Milpa\Live\ValueObjects\ComponentContext $context): Milpa\Live\ValueObjects\StateSnapshot

Mounts with the services the booted plugins declare right now, probed right now.

Parameters

Parameters of mount()
NameTypeDescription
$propsarray
$contextMilpa\Live\ValueObjects\ComponentContext

StackComponent::handle()

public function handle(Milpa\Live\ValueObjects\InteractionRequest $request): Milpa\Live\ValueObjects\InteractionResult

Refuses every action: the section is read-only.

Parameters

Parameters of handle()
NameTypeDescription
$requestMilpa\Live\ValueObjects\InteractionRequest