| Safe Haskell | None |
|---|---|
| Language | GHC2021 |
Ecluse.Core.Package.InvalidEntry
Description
The drop-tracking vocabulary a registry projection records a malformed entry in.
The record reaches an operator log line and an upstream-supplied value can carry a credential,
so mkInvalidEntry is the only builder and the constructor stays hidden. The kinds span every
ecosystem, and the neutral serve diagnostics bucket them through dropCountsByKind rather than
branching on them.
Synopsis
- data InvalidEntry
- mkInvalidEntry :: InvalidEntryKind -> Text -> Value -> Text -> InvalidEntry
- data InvalidEntryKind
- renderInvalidEntryKind :: InvalidEntryKind -> Text
- dropCountsByKind :: [InvalidEntry] -> Map Text Int
A dropped entry
data InvalidEntry Source #
A single registry-document entry a projection dropped as malformed rather than failing the whole document, kept so an operator can see that an upstream served one, and which.
Instances
| Show InvalidEntry Source # | |
Defined in Ecluse.Core.Package.InvalidEntry Methods showsPrec :: Int -> InvalidEntry -> ShowS # show :: InvalidEntry -> String # showList :: [InvalidEntry] -> ShowS # | |
| Eq InvalidEntry Source # | |
Defined in Ecluse.Core.Package.InvalidEntry | |
mkInvalidEntry :: InvalidEntryKind -> Text -> Value -> Text -> InvalidEntry Source #
Record a dropped entry, reducing every URL in the key and the value to its authority: an upstream-supplied artifact location can carry a credential, and this record reaches a log line.
Which kind of entry dropped
data InvalidEntryKind Source #
Which kind of registry-document entry a dropped InvalidEntry came from. A dropped manifest
or index file loses a serve candidate, a dropped tag, time or listing only its own datum.
Constructors
| InvalidVersionManifest | A |
| InvalidDistTag | A |
| InvalidPublishTime | A |
| InvalidIndexFile | A Simple-index file entry that did not project (no name or location, an unusable digest). |
| InvalidVersionListing | A versions-listing entry that was not a usable version string. |
Instances
| Show InvalidEntryKind Source # | |
Defined in Ecluse.Core.Package.InvalidEntry Methods showsPrec :: Int -> InvalidEntryKind -> ShowS # show :: InvalidEntryKind -> String # showList :: [InvalidEntryKind] -> ShowS # | |
| Eq InvalidEntryKind Source # | |
Defined in Ecluse.Core.Package.InvalidEntry Methods (==) :: InvalidEntryKind -> InvalidEntryKind -> Bool # (/=) :: InvalidEntryKind -> InvalidEntryKind -> Bool # | |
| Ord InvalidEntryKind Source # | |
Defined in Ecluse.Core.Package.InvalidEntry Methods compare :: InvalidEntryKind -> InvalidEntryKind -> Ordering # (<) :: InvalidEntryKind -> InvalidEntryKind -> Bool # (<=) :: InvalidEntryKind -> InvalidEntryKind -> Bool # (>) :: InvalidEntryKind -> InvalidEntryKind -> Bool # (>=) :: InvalidEntryKind -> InvalidEntryKind -> Bool # max :: InvalidEntryKind -> InvalidEntryKind -> InvalidEntryKind # min :: InvalidEntryKind -> InvalidEntryKind -> InvalidEntryKind # | |
renderInvalidEntryKind :: InvalidEntryKind -> Text Source #
The operator-facing label for a drop kind. It is the bucket key an operator filters on, so it is held stable as this text rather than the constructor name.
dropCountsByKind :: [InvalidEntry] -> Map Text Int Source #
How many entries dropped under each kind's label. Only the kinds actually seen appear, so a document's drop profile carries no bucket its ecosystem has no entries for.