Statsd.jl

A Julia StatsD Client
Author glenn-m
Popularity
0 Stars
Updated Last
2 Years Ago
Started In
October 2020

Statsd.jl

CI codecov

A basic implementation of a Julia StatsD client.

Quickstart

julia> Pkg.add("Statsd")
julia> using Statsd

Usage

Statsd.jl defaults to sending metrics to 127.0.0.1:8125.

You can specify a hostname, port and a prefix as well.

# Setup the statsd client
client = Statsd.Client("172.10.0.3", 9003, "company.project.cluster")

Counters

# increment http.requests bucket
Statsd.incr(client,"http.requests")
# decrement http.requests bucket
Statsd.decr(client,"http.requests")

Timers

# job.duration took 500ms to complete
Statsd.timing(client,"job.duration",500)

Gauges

# Set disk.usage value to 1029
Statsd.gauge(client,"disk.usage",1029)

Sets

# Set unique.occurence to 3001
Statsd.set(client,"unique.occurence", 3001)

For more information please refer to the StatsD project.