hydra-node
Safe HaskellSafe-Inferred
LanguageGHC2021

Hydra.Logging.Monitoring.Registry

Description

Described metrics and compatibility aliases backed by the Prometheus client.

Synopsis

Documentation

data Registry Source #

Constructors

Registry 

Fields

describe :: Registry -> Text -> Text -> Text -> IO () Source #

counter :: Registry -> Text -> Text -> [(Text, Text)] -> IO Counter Source #

gauge :: Registry -> Text -> Text -> [(Text, Text)] -> IO Gauge Source #

sampledCounter :: Registry -> Text -> Text -> IO Gauge Source #

Absolute, possibly fractional counters (e.g. RTS CPU seconds). The client's incrementable Counter stores Int; sample these through a Gauge handle and publish their counter type. Callers supply monotonically increasing values.

histogram :: Registry -> Text -> Text -> [Double] -> [(Text, Text)] -> IO Histogram Source #

alias :: Registry -> Text -> Text -> Double -> IO () Source #

Both names are rendered from exactly the same sample. Histogram aliases scale the sum and bucket boundaries together; counts remain unchanged.

scaleSample :: Double -> MetricSample -> MetricSample Source #