Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Erlang stats aggregation app that periodically flushes data to a graphing system of your choice, e.g. Graphite or Librato Metrics
Erlang
branch: master

This branch is 20 commits ahead, 2 commits behind wooga:master

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.
src
.gitignore
LICENSE
README.markdown
rebar.config

README.markdown

Still undergoing changes.

estatsd

Heavily modified fork of the Johannesh estatsd.

Major Changes

  • Packaged as an application rather then a release.
  • 3 kinds of stat reporting: counters, gauges and average.
  • Adapter management changed to a gen_server based infrastructure with a supervisor monitoring adapter workers.

Installation & Usage

Package it however you want, set up your app.config and do estatsd:start()

Counters

On flush, counters send a delta to the adapters. This behaviour is different then in the other estatsd implementations, which essentialy sent a value equal to counts/flush_interval.

%%increments by 1
estatsd:increment(counter1).
%%increments by 5
estatsd:increment(counter1,5).
%%increments by 5/0.5
estatsd:increment(counter1,5,0.5).

Gauges

Gauges measure a numeric value at a point in time. The last value for the gauge for the given flush interval is reported as the value. If the adapter supports more advance reporting (eg. Librato's gauge api) then those may be reported as well.

estatsd:gauge(gauge1,10).

Averages

Similar to gauges except all reports for the given flush interval will be averaged before reporting

estatsd:avg(avg1,10).

Application Configuration

The udp args aren't present anymore (for now). The flush interval should be in milliseconds. The adapter specs are either a 3-tuple {Label,Module,Args} where Label is unique among all adapters and Module implements an estatsd_adapter behaviour or {Module,Args} where the label will be defaulted to Module.

[{estatsd,
  [{flush_interval,5000},
   {adapters,[{stathat1,estatsda_stathat_ez,[{token,"<stathat-ez-api-key>"}]},
              {estatsda_logger,[]}
             ]
   }
  ]}
].
Something went wrong with that request. Please try again.