Skip to content

Commit 39faaec

Browse files
committed
fix: replace the collection endpoint while keeping trace ids
1 parent 3e1cdf3 commit 39faaec

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

internal/tracer/tracer.go

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,11 +29,14 @@ func SetupTracer(isDev bool, disableTelemetry bool) (io.Closer, opentracing.Trac
2929
if isDev {
3030
collectorEndpoint = "https://dev.slackb.com/traces/v1/jaeger"
3131
}
32+
if disableTelemetry {
33+
collectorEndpoint = ""
34+
}
3235

3336
// Recommended configuration for production.
3437
var jCfg = jaegercfg.Configuration{
3538
ServiceName: "slack-cli", // Don't change this. Required to distinguish logs & traces coming from the CLI
36-
Disabled: disableTelemetry,
39+
Disabled: false, // Keep tracer active so span contexts and trace IDs are still generated
3740
Reporter: &jaegercfg.ReporterConfig{
3841
LogSpans: false,
3942
CollectorEndpoint: collectorEndpoint,

0 commit comments

Comments
 (0)