Skip to content

Instantly share code, notes, and snippets.

@ScheerMT ScheerMT/statsd.rb forked from leehambley/statsd.rb
Last active Sep 15, 2015

What would you like to do?
#!/usr/bin/env ruby
# vim: set ft=ruby
require 'socket'
require 'term/ansicolor'
include Term::ANSIColor
$stdout.sync = true
c = Term::ANSIColor
s =
s.bind(nil, 8125)
while blob = s.recvfrom(1024)
metric, value = blob.first.split(':')
puts "StatsD Metric: #{} #{}"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.