| Safe Haskell | None |
|---|---|
| Language | GHC2021 |
Ecluse.Composition.MemoryPlan.Override
Description
The one refusal: an explicit override that breaks the plan. A pinned bound never sheds, so it answers for its own bytes. The plan re-derives the override-free minimum, with every pin substituted out and every computed tenant at the floor the shed ladder reaches, and refuses just when that minimum fits the ceiling while the pinned plan does not. It names the pins whose individual removal would fit, or all of them when only their combination overshoots. A pod too small even without the pins degrades through Ecluse.Composition.MemoryPlan.Shed like any other.
Synopsis
- noOverridePins :: OverridePins
- configuredPins :: PlanInputs -> OverridePins
- overrideMinShedSum :: TenantDemands -> OverridePins -> Int
- overrideSubstitutions :: OverridePins -> [(Text, OverridePins)]
- overrideFreeOvershoot :: TenantDemands -> Int
- overrideViolationsFor :: TenantDemands -> ShedOutcomes -> [Text]
- attributeOverrideViolations :: Int -> Int -> Int -> [(Text, Int)] -> [Text]
The pin set
noOverridePins :: OverridePins Source #
Every override substituted out: the pin set the override-free minimum resolves from.
configuredPins :: PlanInputs -> OverridePins Source #
The pin set the operator's configuration actually carries.
The substitution arithmetic
overrideMinShedSum :: TenantDemands -> OverridePins -> Int Source #
The fully-shed minimum tenant sum for a pin set. Each unpinned tenant contributes the floor the shed ladder reaches. Comparing pin sets attributes an overshoot to its pins.
overrideSubstitutions :: OverridePins -> [(Text, OverridePins)] Source #
Each explicit override present in the pin set, paired with the pin set that substitutes only it out, and with the operator's config-key name.
overrideFreeOvershoot :: TenantDemands -> Int Source #
The overshoot with every pin substituted out. Above zero, the pod is too small whatever the operator configured, so no pin is to blame.
The refusal
overrideViolationsFor :: TenantDemands -> ShedOutcomes -> [Text] Source #
The plan's own refusal decision, over its resolved demands and shed outcomes.