ermine-0.6: Ermine

Safe HaskellNone
LanguageHaskell2010

Ermine.Monitor

Contents

Synopsis

Documentation

withMonitor :: HasMonitorOptions t => t -> (Monitor -> IO a) -> IO a Source

The Monitor

class HasMonitor t where Source

Minimal complete definition

monitor

Instances

Gauges

newtype Gauge Source

Constructors

Gauge 

Fields

runGauge :: Maybe Gauge
 

gauge :: (MonadIO m, HasMonitor t) => Text -> t -> m Gauge Source

gaugeM :: (MonadIO m, MonadReader t m, HasMonitor t) => Text -> m Gauge Source

create a gauge

Counters

newtype Counter Source

Constructors

Counter 

Fields

runCounter :: Maybe Counter
 

Instances

counter :: (MonadIO m, HasMonitor t) => Text -> t -> m Counter Source

counterM :: (MonadIO m, MonadReader t m, HasMonitor t) => Text -> m Counter Source

create a counter

Labels

newtype Label Source

Constructors

Label 

Fields

runLabel :: Maybe Label
 

Instances

label :: (MonadIO m, HasMonitor t) => Text -> t -> m Label Source

labelM :: (MonadIO m, MonadReader t m, HasMonitor t) => Text -> m Label Source

create a label

Compatibilty with EKG

data Server :: *

withServer :: HasMonitor t => t -> (Server -> IO ()) -> IO () Source

Modifiers

Options