ReleaseJournal
Corex\Config\Releases\ReleaseJournal · class · Config layer
What a swap is about to do and how far it has got, written before it is done (spec 107, plan D6; FR-022). previous/journal.json: each rename of the swap, in order, with where the folder is and where it goes. A rename is marked started before it is made and done after. A request that dies between two renames leaves this file saying exactly which were made, and one that dies during a rename leaves one started, which the folders themselves then answer. It is kept with the folders that were replaced, because going back is this list read backwards: by the Releases screen, and by the recovery file that runs when CoreX cannot.
Public API
Section titled “Public API”__construct(ReleaseStore $store)
Section titled “__construct(ReleaseStore $store)”begin(array $moves, array $about): void
Section titled “begin(array $moves, array $about): void”Write down a swap before any of it is made.
status(): ?string
Section titled “status(): ?string”Where the last swap stands; null when there has been none.
about(): array
Section titled “about(): array”What the last swap was of, as whoever began it said.
isOf(string $keyHash): bool
Section titled “isOf(string $keyHash): bool”Whether the last swap is the one of the installation whose key has this hash: whoever began it said so in what it is of, as for.
moves(): array
Section titled “moves(): array”mark(int $move, string $state): void
Section titled “mark(int $move, string $state): void”close(string $status, string $refused): void
Section titled “close(string $status, string $refused): void”refused(): string
Section titled “refused(): string”The folder that would not move, when the last swap ended for that reason.
file(): string
Section titled “file(): string”Where the journal is, for the recovery file that reads it when CoreX cannot.