Document and add support to input plugins for logging alias (#6357)

This commit is contained in:
Greg
2019-09-23 16:39:50 -06:00
committed by Daniel Nelson
parent e42d2e39c6
commit 817c9a69a9
111 changed files with 961 additions and 659 deletions

View File

@@ -3,7 +3,6 @@ package zipkin
import (
"context"
"fmt"
"log"
"net"
"net/http"
"strconv"
@@ -60,6 +59,8 @@ type Zipkin struct {
Port int
Path string
Log telegraf.Logger
address string
handler Handler
server *http.Server
@@ -105,7 +106,7 @@ func (z *Zipkin) Start(acc telegraf.Accumulator) error {
}
z.address = ln.Addr().String()
log.Printf("I! Started the zipkin listener on %s", z.address)
z.Log.Infof("Started the zipkin listener on %s", z.address)
go func() {
wg.Add(1)

View File

@@ -562,6 +562,7 @@ func TestZipkinPlugin(t *testing.T) {
DefaultNetwork = "tcp4"
z := &Zipkin{
Log: testutil.Logger{},
Path: "/api/v1/spans",
Port: 0,
}