Revert "Revert graylog output"

This reverts commit 4f27315720.
This commit is contained in:
Cameron Sparr 2016-05-31 16:42:07 +01:00
parent 342cfc4087
commit c4cfdb8a25
4 changed files with 16 additions and 1 deletions

View File

@ -233,6 +233,7 @@ want to add support for another service or third-party API.
* [datadog](https://github.com/influxdata/telegraf/tree/master/plugins/outputs/datadog) * [datadog](https://github.com/influxdata/telegraf/tree/master/plugins/outputs/datadog)
* [file](https://github.com/influxdata/telegraf/tree/master/plugins/outputs/file) * [file](https://github.com/influxdata/telegraf/tree/master/plugins/outputs/file)
* [graphite](https://github.com/influxdata/telegraf/tree/master/plugins/outputs/graphite) * [graphite](https://github.com/influxdata/telegraf/tree/master/plugins/outputs/graphite)
* [graylog](https://github.com/influxdata/telegraf/tree/master/plugins/outputs/graylog)
* [instrumental](https://github.com/influxdata/telegraf/tree/master/plugins/outputs/instrumental) * [instrumental](https://github.com/influxdata/telegraf/tree/master/plugins/outputs/instrumental)
* [kafka](https://github.com/influxdata/telegraf/tree/master/plugins/outputs/kafka) * [kafka](https://github.com/influxdata/telegraf/tree/master/plugins/outputs/kafka)
* [librato](https://github.com/influxdata/telegraf/tree/master/plugins/outputs/librato) * [librato](https://github.com/influxdata/telegraf/tree/master/plugins/outputs/librato)

View File

@ -205,6 +205,12 @@
# timeout = 2 # timeout = 2
# # Send telegraf metrics to graylog(s)
# [[outputs.graylog]]
# ## Udp endpoint for your graylog instance.
# servers = ["127.0.0.1:12201", "192.168.1.1:12201"]
# # Configuration for sending metrics to an Instrumental project # # Configuration for sending metrics to an Instrumental project
# [[outputs.instrumental]] # [[outputs.instrumental]]
# ## Project API Token (required) # ## Project API Token (required)

View File

@ -3,3 +3,12 @@
This plugin writes to a Graylog instance using the "gelf" format. This plugin writes to a Graylog instance using the "gelf" format.
It requires a `servers` name. It requires a `servers` name.
### Configuration:
```toml
# Send telegraf metrics to graylog(s)
[[outputs.graylog]]
## Udp endpoint for your graylog instance.
servers = ["127.0.0.1:12201", "192.168.1.1:12201"]
```

View File

@ -24,7 +24,6 @@ func TestWrite(t *testing.T) {
i.Connect() i.Connect()
metrics := testutil.MockMetrics() metrics := testutil.MockMetrics()
metrics = append(metrics, testutil.TestMetric(int64(1234567890)))
i.Write(metrics) i.Write(metrics)