Skip to content

Instantly share code, notes, and snippets.

@walkeran
Created May 30, 2014 20:56
Show Gist options
  • Save walkeran/9b4ab4b90e2506b25695 to your computer and use it in GitHub Desktop.
Save walkeran/9b4ab4b90e2506b25695 to your computer and use it in GitHub Desktop.
Logstash + JSON Codec + StatsD
input {
redis {
key => 'logstash:collect'
data_type => 'list'
codec => json
type => 'collect'
}
}
output {
statsd {
# Just throw this at the root for now. Sick of expanding graphite trees.
namespace => ""
sender => ""
# Tried with: increment, [increment] ... neither work. Seems that nothing is passed to statsd
# Tried with: "%{increment}" ... as expected, a concatenated list of arr entries is used as the counter name
increment => increment
}
}
{
"increment":[
"metric1",
"metric2"
]
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment