| Safe Haskell | None |
|---|---|
| Language | GHC2021 |
Ecluse.Core.Telemetry.Record
Description
Backend-neutral recording ports for the serve path, mirror worker, Dredger and advisory tasks. Each port accepts the bounded labels defined in Ecluse.Core.Telemetry.Metrics. The application supplies telemetry implementations. Polled gauges remain outside these ports.
Synopsis
- data MetricsPort = MetricsPort {
- mpServeDecision :: Decision -> IO ()
- mpServeAdmissionInFlight :: Int -> IO ()
- mpServeAdmissionQueued :: IO ()
- mpMemoryAdmissionQueued :: IO ()
- mpMemoryAdmissionShed :: IO ()
- mpMemoryAdmissionPause :: IO ()
- mpMemoryAdmissionOverdraw :: IO ()
- mpPublishBodyInFlightBytes :: Int -> IO ()
- mpPublishBodyShed :: IO ()
- mpMergeDivergence :: IO ()
- mpRuleDenial :: Maybe Text -> ReasonClass -> IO ()
- mpRuleEvalDuration :: Tier -> Double -> IO ()
- mpRuleEffectfulFailure :: Cause -> IO ()
- mpUpstreamFetch :: Upstream -> StatusClass -> Double -> IO ()
- mpUpstreamFetchError :: Upstream -> Cause -> IO ()
- mpCacheRequest :: CacheResult -> IO ()
- mpVersionCacheRequest :: CacheResult -> IO ()
- mpAssembledCacheRequest :: CacheResult -> IO ()
- mpCacheRefused :: CacheStore -> IO ()
- mpCacheEntries :: Int -> IO ()
- mpCacheResidentBytes :: Int -> IO ()
- mpVersionCacheResidentBytes :: Int -> IO ()
- mpAssembledCacheResidentBytes :: Int -> IO ()
- mpPublicRelayAnomaly :: RelayAnomaly -> IO ()
- mpRequestPerimeterFault :: RequestFaultCause -> IO ()
- mpMirrorEnqueued :: IO ()
- mpMirrorEnqueueFailure :: IO ()
- data WorkerMetricsPort = WorkerMetricsPort {
- wmpMirrorJobProcessed :: MirrorResult -> IO ()
- wmpMirrorPublishDuration :: Double -> IO ()
- newtype DredgerMetricsPort = DredgerMetricsPort {
- dmpSweptVersion :: SweepTarget -> SweepResult -> IO ()
- data AdvisorySyncMetricsPort = AdvisorySyncMetricsPort {
- asmpSyncAttempt :: Ecosystem -> AdvisorySyncResult -> IO ()
- asmpSyncDuration :: Ecosystem -> AdvisorySyncResult -> Double -> IO ()
- data AdvisoryCompileMetricsPort = AdvisoryCompileMetricsPort {
- acmpCompileAccepted :: Int -> IO ()
- acmpCompileDropped :: AdvisoryDropCause -> Int -> IO ()
- acmpCompileRun :: AdvisoryCompileResult -> IO ()
- timedSeconds :: MonadIO m => m a -> m (a, Double)
The serve-path recording port
data MetricsPort Source #
The metric-recording port over a telemetry backend, one field per ecluse.* signal.
The closed label types in Ecluse.Core.Telemetry.Metrics bound each signal's cardinality.
Constructors
| MetricsPort | |
Fields
| |
The worker recording port
data WorkerMetricsPort Source #
The mirror worker's metric-recording port: the worker analogue of MetricsPort. The two
consumers share no field. Ecluse.Runtime.Telemetry.Instruments supplies the OTel implementation.
Constructors
| WorkerMetricsPort | |
Fields
| |
The mirror sweep recording port
newtype DredgerMetricsPort Source #
The mirror sweep's metric-recording port, recorded by Ecluse.Core.Registry.Sweep. The package and version a disposition concerns ride the sweep's own audit line, never a label.
Constructors
| DredgerMetricsPort | |
Fields
| |
The advisory sync recording port
data AdvisorySyncMetricsPort Source #
The advisory sync task's metric-recording port, recorded by the sync loop in
Ecluse.Runtime.Cve.Sync. Ecosystem and result are the only labels, so the series stays bounded.
Constructors
| AdvisorySyncMetricsPort | |
Fields
| |
The advisory compile recording port
data AdvisoryCompileMetricsPort Source #
The Pilot compile's metric-recording port. One port is bound to one ecosystem, so no field carries the ecosystem the compile holds as free text.
Constructors
| AdvisoryCompileMetricsPort | |
Fields
| |
Timing
timedSeconds :: MonadIO m => m a -> m (a, Double) Source #
Run an action and return its result with the elapsed seconds. It measures on the monotonic clock, so a system-clock step never yields a negative or absurd duration.