StatsD Configuration

StatsD Statistics

The statsd top-level configuration object is used to define a destination for the delivery of statistics counters in StatsD format. Statistics counter values are only stored in memory and will be lost when N2SVCD is restarted. If you wish to maintain a permanent record of statistics counters then you must deliver output statistics to a separate StatsD server (such as Telegraf or Prometheus).

An example StatsD configuration using Telegraf-specific output might be:

    <statsd>
        <host>localhost</host>
        <tags>
            <tag name="foo" value="bar"/>
            <tag name="foo2" value="bar2"/>
        </tags>
    </statsd>

Note that statistics that have never been incremented are not sent over StatsD. Downstream systems can safely treat any absent statistics as having a zero value for the applicable time period. Once incremented, statistics values will continue to be sent for each statistics slice. Statistics slices are covered in greater detail as part of Management Summary Response Messages.

Configuration Details

The statsd configuration object supports the following attributes:

Attribute Type Description
host String IPv4 hostname or A.B.C.D address for the UDP StatsD destination.
(Default = 127.0.0.1)
port Integer Port number for UDP StatsD destination.
(Default = 8125)
tags Array Additional static tags to be sent for all statistics. Each tag must specify a name and a value. Configured tags may be overridden at runtime.

All attributes other than tags and the content of each tag value may be evaluated.

Note that statistics will be sent externally if the statsd configuration block exists at all in the configuration, even if it is empty.

Automatic Statistic Tags

The following tags are always populated:

All automatically-added tag names may not be defined manually.