Skip to content

Commit

Permalink
tracing: fix tracer closing
Browse files Browse the repository at this point in the history
ContextWithRecording span was closing the passed-in Tracer, which is
completely wrong. This has been broken since a long time ago; the
function originally was written to create its own Tracer but then
changed to take in a Tracer and the bad close remained.

As a practical consequence, tracing to external tracers stopped whenever
one of the debug pages that uses this utility was used.

Release note (bug fix): Fixed a bug causing tracing to external tracers
to inadvertently stop after the Enqueue Range or the Allocator debug
pages was used.
  • Loading branch information
andreimatei committed Nov 4, 2021
1 parent f84b8e7 commit 3653235
Showing 1 changed file with 0 additions and 1 deletion.
1 change: 0 additions & 1 deletion pkg/util/tracing/tracer.go
Original file line number Diff line number Diff line change
Expand Up @@ -1057,7 +1057,6 @@ func ContextWithRecordingSpan(
cancel = func() {
cancelCtx()
sp.Finish()
tr.Close()
}
return ctx, sp.GetRecording, cancel
}
Expand Down

0 comments on commit 3653235

Please sign in to comment.