mirror of
https://github.com/coredns/coredns.git
synced 2025-11-02 10:13:14 -05:00
Follow up on PR 2868 (#2877)
This fix is a follow up on comment https://github.com/coredns/coredns/pull/2868#discussion_r291609761 Signed-off-by: Yong Tang <yong.tang.github@outlook.com>
This commit is contained in:
@@ -54,7 +54,8 @@ func (t *trace) OnStartup() error {
|
||||
case "zipkin":
|
||||
err = t.setupZipkin()
|
||||
case "datadog":
|
||||
t.setupDatadog()
|
||||
tracer := opentracer.New(tracer.WithAgentAddr(t.Endpoint), tracer.WithServiceName(t.serviceName), tracer.WithDebugMode(true))
|
||||
t.tracer = tracer
|
||||
default:
|
||||
err = fmt.Errorf("unknown endpoint type: %s", t.EndpointType)
|
||||
}
|
||||
@@ -75,11 +76,6 @@ func (t *trace) setupZipkin() error {
|
||||
return err
|
||||
}
|
||||
|
||||
func (t *trace) setupDatadog() {
|
||||
tracer := opentracer.New(tracer.WithAgentAddr(t.Endpoint), tracer.WithServiceName(t.serviceName), tracer.WithDebugMode(true))
|
||||
t.tracer = tracer
|
||||
}
|
||||
|
||||
// Name implements the Handler interface.
|
||||
func (t *trace) Name() string { return "trace" }
|
||||
|
||||
|
||||
Reference in New Issue
Block a user