Skip to content

Instantly share code, notes, and snippets.

@robertely
Last active December 18, 2015 11:59
Show Gist options
  • Save robertely/5779287 to your computer and use it in GitHub Desktop.
Save robertely/5779287 to your computer and use it in GitHub Desktop.
Logstash - > Graphite Local Proxy
input {
tcp{
port => 2003
type => "graphite"
mode => "server"
}
}
filter {
grok {
pattern => "%{DATA:name} %{NUMBER:value:float} %{POSINT:ts}"
singles => true
type => "graphite"
}
date {
type => "graphite"
match => ["ts", UNIX]
}
mutate {
type => "graphite"
remove => ts
gsub =>[
"name", ".value", ""
,"name", "counter-", ""
,"name", "gauge-", ""
]
}
}
output {
# stdout { debug => true debug_format => "ruby" type => "graphite"}
rabbitmq {
host => "rmq-10002-prod-nydc1.nydc1.outbrain.com"
vhost => "logstash"
user => "logstash"
password => "logstash"
exchange => "logstash.graphite.out"
exchange_type => "fanout"
durable => false # If rabbitmq restarts, the exchange disappears.
persistent => false # Messages are not persisted to disk
type => "graphite"
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment