hs-abci-sdk-0.1.0.0

Safe HaskellNone
LanguageHaskell2010

Tendermint.SDK.BaseApp.Metrics.Prometheus

Contents

Synopsis

Documentation

Config and Setup

data MetricsScrapingConfig Source #

Core metrics config

Constructors

MetricsScrapingConfig 

Fields

data MetricsState Source #

Constructors

MetricsState 

Fields

metricsCounters :: Lens' MetricsState (MVar (MetricsMap Counter)) Source #

metricsHistograms :: Lens' MetricsState (MVar (MetricsMap Histogram)) Source #

Utils

mkPrometheusMetricId :: MetricIdentifier -> MetricId Source #

Prometheus registry index key

metricIdStorable :: MetricIdentifier -> (Text, Labels) Source #

Index key for storing metrics

countToIdentifier :: CountName -> MetricIdentifier Source #

Eval

evalWithMetrics :: Member (Embed IO) r => Member (Reader (Maybe PrometheusEnv)) r => Sem (Metrics ': r) a -> Sem r a Source #

evalNothing :: Sem (Metrics ': r) a -> Sem r a Source #

evalMetrics :: Member (Embed IO) r => MetricsState -> Sem (Metrics ': r) a -> Sem r a Source #

Increments existing count, if it doesn't exist, creates a new | counter and increments it.