Documentation ¶
Overview ¶
Package datadog defines configuration and functions for emitting metrics to Datadog using the DogStatd protocol.
It supports a special format for metric names to add metric-specific tags:
metricName[tag1,tag2:value2,...]
Global tags for all metrics can be set in the configuration.
Note that rcrowley/go-metrics and DogStatsd define counters in different ways: counters in DogStatsd are reported over an interval and reset to zero at the start of each period while go-metrics counters are running totals that are more like gauges with internal state. This package follows the DogStatsd definition and reports the change in counter values between emmit calls. The go-metrics behavior can be simulated at analysis time in Datadog by taking cumulative sums.
Index ¶
Constants ¶
const ( DefaultAddress = "127.0.0.1:8125" DefaultInterval = 10 * time.Second )
Variables ¶
This section is empty.
Functions ¶
func SetTimerUnit ¶
SetTimerUnit sets the units used when exporting metrics.Timer metrics. By default, times are reported in nanoseconds. You must call this function before starting any Emitter instances.