| Safe Haskell | None |
|---|---|
| Language | GHC2021 |
Ecluse.Core.Cve.Slot
Description
Advisory generations stay pinned for each lookup. Retirement belongs to the last reader, or to the swapper when no readers remain, even if the swapper is cancelled.
Synopsis
- data CveSlot
- newCveSlot :: IO CveSlot
- withSlotGeneration :: CveSlot -> (Maybe (DbEtag, CveLookup) -> IO a) -> IO a
- currentAdvisoryEtag :: CveSlot -> IO (Maybe DbEtag)
- data AdvisorySource = AdvisorySource {}
- currentAdvisorySource :: CveSlot -> IO (Maybe AdvisorySource)
- observeAdvisoryPublication :: CveSlot -> DbEtag -> Maybe UTCTime -> IO ()
- generationInstalledAt :: CveSlot -> IO (Maybe Double)
- swapIn :: CveSlot -> DbEtag -> Maybe UTCTime -> CveDb -> IO ()
Documentation
withSlotGeneration :: CveSlot -> (Maybe (DbEtag, CveLookup) -> IO a) -> IO a Source #
Borrow a lookup and its own ETag together until the action returns or is cancelled.
data AdvisorySource Source #
Where the serving artifact came from. The publication time is the store's, not the artifact's, so republishing the same bytes can advance it.
Constructors
| AdvisorySource | |
Fields
| |
Instances
| Show AdvisorySource Source # | |
Defined in Ecluse.Core.Cve.Slot Methods showsPrec :: Int -> AdvisorySource -> ShowS # show :: AdvisorySource -> String # showList :: [AdvisorySource] -> ShowS # | |
| Eq AdvisorySource Source # | |
Defined in Ecluse.Core.Cve.Slot Methods (==) :: AdvisorySource -> AdvisorySource -> Bool # (/=) :: AdvisorySource -> AdvisorySource -> Bool # | |
currentAdvisorySource :: CveSlot -> IO (Maybe AdvisorySource) Source #
observeAdvisoryPublication :: CveSlot -> DbEtag -> Maybe UTCTime -> IO () Source #
Advance publication time only for the installed ETag, without replacing or retiring its database.