Portability | non-portable (GHC extensions) |
---|---|
Stability | experimental |
Maintainer | Brendan Hay <brendan@soundcloud.com> |
Safe Haskell | Safe-Infered |
- data Slope
- = Zero
- | Positive
- | Negative
- | Both
- | Unspecified
- data GangliaType
- data GangliaMetric = GangliaMetric {
- name :: ByteString
- type' :: GangliaType
- units :: ByteString
- value :: ByteString
- host :: ByteString
- spoof :: ByteString
- group :: ByteString
- slope :: Slope
- tmax :: Word32
- dmax :: Word32
- data Ganglia = Ganglia Handle
- defaultMetric :: GangliaMetric
- putMetaData :: GangliaMetric -> Put
- putValue :: GangliaMetric -> Put
- open :: String -> String -> IO Sink
- class MetricSink a where
- type Group = ByteString
- type Bucket = ByteString
- type Value = ByteString
- data MetricType
- data Metric = Metric MetricType Group Bucket Value
Exported Types
Allows gmetad and the PHP webfrontend to efficiently separate constant data metrics from volatile ones
data GangliaType Source
Metric types supported by Ganglia
data GangliaMetric Source
Concrete metric type used to emit metadata and value packets
GangliaMetric | |
|
Defaults
defaultMetric :: GangliaMetricSource
Sensible defaults for a GangliaMetric
Binary Encoding
putMetaData :: GangliaMetric -> PutSource
Encode a GangliaMetric's metadata into a Binary.Put monad
The format for this can be found in either: * gm_protocol.x in the Ganglia 3.1 sources * https:github.comlookfirstjmxtrans
putValue :: GangliaMetric -> PutSource
Encode a GangliaMetric's value into a Binary.Put monad
Sink Functions
class MetricSink a whereSource
Sink resource to write metrics to
MetricSink Sink | Existential sink instance |
MetricSink Ganglia | |
MetricSink Graphite | |
MetricSink Statsd | |
MetricSink StdoutSink |
Re-exports
type Group = ByteStringSource
Metric group
type Bucket = ByteStringSource
Metric bucket
type Value = ByteStringSource
Metric value