ReleaseInstallation
Corex\Config\Releases\ReleaseInstallation · class · Config layer
An installation, from the package an administrator chose to the release being in place (spec 107, US1; plan D8; FR-015, FR-018, FR-020, FR-023, FR-050). It is asked for a piece at a time, each a request the browser makes. prepare states what would be installed and gives the administrator the way back. confirm takes the version typed. step does the next piece until the release is in place. cancel gives up one that has not moved anything. What comes after the files are in place is ReleaseCompletion, which the release just installed answers. One at a time: each of these holds the installer’s lock, and a prepared or running installation refuses another.
Public API
Section titled “Public API”__construct(ReleaseStore $store, ReleaseDesk $desk, InstalledRelease $installed, ReleaseSteps $steps, ReleaseSafeguards $safeguards, ReleaseRecord $record, string $siteRoot)
Section titled “__construct(ReleaseStore $store, ReleaseDesk $desk, InstalledRelease $installed, ReleaseSteps $steps, ReleaseSafeguards $safeguards, ReleaseRecord $record, string $siteRoot)”prepare(string $package, int $actorId, DateTimeImmutable $now): array
Section titled “prepare(string $package, int $actorId, DateTimeImmutable $now): array”State what installing a package would do, and give the way back, before anything is asked for. Nothing of the site changes. The key in the answer is made here and kept nowhere: the browser holds it for the installation, and the administrator is given the recovery link it is part of.
confirm(ReleaseConfirmationGiven $given, int $actorId, DateTimeImmutable $now): array
Section titled “confirm(ReleaseConfirmationGiven $given, int $actorId, DateTimeImmutable $now): array”Take the administrator’s confirmation: the version, typed.
step(int $actorId, DateTimeImmutable $now): array
Section titled “step(int $actorId, DateTimeImmutable $now): array”Do the next piece of the installation.
standingForTheScreen(): ?array
Section titled “standingForTheScreen(): ?array”The installation in progress as the screen is told of it, with whether it can be given up; or none.
cancel(int $actorId, DateTimeImmutable $now): void
Section titled “cancel(int $actorId, DateTimeImmutable $now): void”Give up an installation that has not moved anything of the site: before the swap, or at it before its first folder moved (FR-022a).