ecluse:ecluse-core
Safe HaskellNone
LanguageGHC2021

Ecluse.Core.Registry.Sweep.Outcome

Description

What one sweep cycle did, why it stopped early if it did, and what it could not read.

A count is only as good as the evidence behind it, so a cycle reports its halt and its gaps beside its tally rather than folding them in. The rendered lines are the operator's, so their wording is the reported behaviour.

Synopsis

What one cycle did

data CycleHalt Source #

Why a cycle stopped before it finished.

Constructors

HaltConsentWithheld Ecosystem Text Text

The store carries no consent marker, with the backend and its how-to-attach text.

HaltStorePreserved Ecosystem Text Text

The store refills itself from elsewhere, so deleting from it changes nothing.

HaltDeletionCap Int Int (Maybe DbEtag)

The cycle reached its deletion cap, carrying the cap, what it handed over, and the advisory generation of the denial that reached it. No later cycle runs.

HaltStoreFault Ecosystem Text Text

A store call produced no answer and its retry advice ran out, carrying the fault.

HaltBucketUnsplittable Ecosystem Text Text

A bucket outgrew the memory budget and nothing narrows it further, so the walk cannot read it within the budget.

Instances

Instances details
Show CycleHalt Source # 
Instance details

Defined in Ecluse.Core.Registry.Sweep.Outcome

Eq CycleHalt Source # 
Instance details

Defined in Ecluse.Core.Registry.Sweep.Outcome

data CycleOutcome Source #

One cycle's result: what it did, why it stopped early if it did, and what it could not read.

Constructors

CycleOutcome 

Fields

outcomeComplete :: CycleOutcome -> Bool Source #

Whether a cycle's counts cover what they claim to: it walked the whole store it was given, and every rule that decided read the facts it needed. Nothing about permission enters here.

latches :: CycleHalt -> Bool Source #

Whether a halt stops the Dredger for the life of the process. Only the cap does, because a breaker that re-closes itself is not a breaker. Every other halt is re-read next cycle.

renderCycleHalt :: CycleHalt -> Text Source #

The operator-facing text of a halt, naming the backend that raised it and what to fix.

renderGeneration :: Maybe DbEtag -> Text Source #

The advisory generation an audit line names, or that none was loaded.

renderTally :: SweepTally -> Text Source #

One cycle's counts, as its closing line reports them.

renderStoreFault :: StoreFault -> Text Source #

A store fault as an operator reads it: the transport's own cause and its bounded detail.

storeSubject :: Ecosystem -> Text -> Text Source #

Name a store without assuming whether it is the mirror or private target.

What a preview found standing in a real sweep's way

data TargetPrerequisites Source #

One target's standing permissions as a preview found them.

Constructors

TargetPrerequisites 

Fields

data PrerequisiteStatus Source #

What a preview could see of one standing permission. A preview exercises none of them, so an unmet one is reported and never acted on.

Constructors

PrerequisiteMet

The store answered, and a real sweep would pass this one.

PrerequisiteUnmet Text

The store answered, and a real sweep would stop here, carrying the backend's own text.

PrerequisiteUnread Text

The store did not answer, so nothing the preview read settles it.

prerequisitesMet :: TargetPrerequisites -> Bool Source #

Whether a real sweep of this target would pass both standing permissions.

renderPrerequisites :: TargetPrerequisites -> Text Source #

One target's line, which a preview prints above its counts. It closes on what no read settles: a preview deletes nothing, so it proves no authority to delete.

What a cycle could not read

data EvidenceGaps Source #

What one cycle could not read. A count taken with a gap open describes part of the store, so it is reported apart from the counts themselves rather than folded into them.

Constructors

EvidenceGaps 

Fields

  • gapAdvisoryGeneration :: Int

    Mounts that decided with no advisory generation loaded, so every advisory rule abstained.

  • gapManifests :: Int

    Packages whose metadata the store did not serve, decided on identity alone.

unloadedGeneration :: EvidenceGaps Source #

The gap one mount deciding without an advisory generation leaves.

unreadManifest :: EvidenceGaps Source #

The gap one package the store served no metadata for leaves.

evidenceComplete :: EvidenceGaps -> Bool Source #

Whether a cycle read every fact its counts rest on.

renderEvidenceGaps :: EvidenceGaps -> Text Source #

What a cycle could not read, as its closing line reports it, naming only what it did miss.