FedericoCeratto / nim-statsd-client

A simple StatsD client for Nim

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

StatsD client for Nim

badge tags License

A simple, stateless StatsD client.

Documentation: module index

Install:

nimble install statsd_client

Usage example:

import statsd_client

let stats = newStatdClient(prefix="foo")
stats.incr("mycnt")
stats.incr("mycnt", 3)
stats.decr("mycnt", 3)
stats.timing("mytimer_float", 110.0)
stats.timing("mytimer_int", 110)
stats.gauge("mygauge", 1.0)
stats.gauge("mygauge", 2)
stats.gauge("mygauge", 1, delta=true)
stats.gauge("mygauge", -2, delta=true)
stats.set("set_one", "a")
stats.set("set_one", "b")
stats.timed("mytimer"):
  slow_proc()

About

A simple StatsD client for Nim

License:GNU Lesser General Public License v3.0


Languages

Language:Nim 100.0%