ekg-rrd-0.2.1.69: Passes ekg statistics to rrdtool

Safe HaskellNone
LanguageHaskell2010

System.Metrics.RRDTool.Internals

Synopsis

Documentation

type IntervalSeconds = Int Source

Intervals in seconds (e.g. heartbeats and step size)

type SourceValue = Int64 Source

Counters, gauges etc. in ekg have this type

data DataSourceType Source

Types of data source in a round-robin database.

Constructors

DsGauge

Metrics whose current value is tracked. This is appropriate for Gauge metrics and creates a GAUGE DS.

DsDerive

Metrics that are monotonically increasing and whose rate-of-change is tracked. This is appropriate for Counter metrics and creates a DERIVE DS.

data DataSource Source

A data source in a round-robin database.

Constructors

DataSource 

Fields

dsName :: Text

The name of the metric in the database. Maximum 19 characters and contains letters, digits and underscores only.

dsMetric :: Text

The name of the metric in the ekg Store.

dsType :: DataSourceType

The type of the metric.

dsHeartBeat :: IntervalSeconds

After this length of time with no updates, consider the value to be 'unknown'.

dsMin :: Maybe SourceValue

Values less than this should be interpreted as 'unknown'.

dsMax :: Maybe SourceValue

Values greater than this should be interpreted as 'unknown'.

gcSources Source

Arguments

:: IntervalSeconds

The heartbeat for these metrics, in seconds.

-> [DataSource] 

Pre-defined data sources for tracking GHC's GC metrics. See registerGcMetrics or GCStats for more details. Clients must run registerGcMetrics to register these metrics once the RRD is created.

data ConsolidationFunction Source

Defines how multiple primary data points (PDPs) are turned into a consolidated data point (CDP) for storage in a RoundRobinArchive.

Constructors

CFLast

Keep the last point only.

CFAverage

Take the mean of the points.

CFMin

Take the minimum point.

CFMax

Take the maximum point.

data RoundRobinArchive Source

A sequence of consolidated data points (CDPs).

Constructors

RoundRobinArchive 

Fields

rraCf :: ConsolidationFunction

How to consolidate PDPs to get each CDP.

rraXff :: Double

The 'Xfiles factor' - if more than this proportion of PDPs is unknown then the CDP is unknown.

rraPdpCount :: Int

The number of PDPs to use to calculate each CDP.

rraRecordCount :: Int

The number of CDPs to store in the archive.

data RoundRobinDatabase Source

A round-robin database (RRD), which is a file on disk that stores time series data from a number of sources.

Constructors

RoundRobinDatabase 

Fields

rrdToolPath :: FilePath
 
rrdFilePath :: FilePath
 
rrdSources :: HashMap Text DataSource
 
rrdArchives :: [RoundRobinArchive]
 
rrdStore :: Store

Get the Store associated with this RoundRobinDatabase in order to register metrics.

rrdStep :: IntervalSeconds