Skip to content
Snippets Groups Projects
Commit 1ff721ad authored by Cameron Sparr's avatar Cameron Sparr
Browse files

Add riemann output plugin deprecation message

parent 3e3b0942
No related branches found
No related tags found
No related merge requests found
...@@ -2,6 +2,7 @@ package riemann ...@@ -2,6 +2,7 @@ package riemann
import ( import (
"fmt" "fmt"
"log"
"os" "os"
"sort" "sort"
"strings" "strings"
...@@ -11,6 +12,8 @@ import ( ...@@ -11,6 +12,8 @@ import (
"github.com/influxdata/telegraf/plugins/outputs" "github.com/influxdata/telegraf/plugins/outputs"
) )
const deprecationMsg = "I! WARNING: this Riemann output plugin will be deprecated in a future release, see https://github.com/influxdata/telegraf/issues/1878 for more details & discussion."
type Riemann struct { type Riemann struct {
URL string URL string
Transport string Transport string
...@@ -29,6 +32,7 @@ var sampleConfig = ` ...@@ -29,6 +32,7 @@ var sampleConfig = `
` `
func (r *Riemann) Connect() error { func (r *Riemann) Connect() error {
log.Printf(deprecationMsg)
c, err := raidman.Dial(r.Transport, r.URL) c, err := raidman.Dial(r.Transport, r.URL)
if err != nil { if err != nil {
...@@ -58,6 +62,7 @@ func (r *Riemann) Description() string { ...@@ -58,6 +62,7 @@ func (r *Riemann) Description() string {
} }
func (r *Riemann) Write(metrics []telegraf.Metric) error { func (r *Riemann) Write(metrics []telegraf.Metric) error {
log.Printf(deprecationMsg)
if len(metrics) == 0 { if len(metrics) == 0 {
return nil return nil
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment