lightstep / lightstep-tracer-go

The Lightstep distributed tracing library for Go
https://lightstep.com
MIT License
98 stars 54 forks source link

Configure service name #210

Closed ppwfx closed 5 years ago

ppwfx commented 5 years ago

Hey guys,

awesome stuff. It's real fun to work with your stack. One think I can't figure out is how to set the service name for a given tracer. To me, all services are labeled "main". Is there any way to change the service name without moving the tracer instantiation to a different package?

cheers

ppwfx commented 5 years ago

That's how it's done

lightstep.NewTracer(lightstep.Options{
    AccessToken: "x",
    Tags: opentracing.Tags{
        lightstep.ComponentNameKey: "spec-svc",
    },
})