Skip to content

Commit 1f85128

Browse files
craig[bot]yuzefovich
andcommitted
Merge #151370
151370: tracing: remove unused WithRemoteParentFromLocalSpan option r=yuzefovich a=yuzefovich Something I noticed while looking into other stuff. Epic: None Release note: None Co-authored-by: Yahor Yuzefovich <[email protected]>
2 parents 186f260 + b652588 commit 1f85128

File tree

1 file changed

+0
-21
lines changed

1 file changed

+0
-21
lines changed

pkg/util/tracing/span_options.go

Lines changed: 0 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -266,27 +266,6 @@ func (p remoteParent) apply(opts spanOptions) spanOptions {
266266
return opts
267267
}
268268

269-
type remoteParentFromLocalSpanOption spanRef
270-
271-
func (r remoteParentFromLocalSpanOption) apply(opts spanOptions) spanOptions {
272-
opts.RemoteParent = r.Meta()
273-
sr := spanRef(r)
274-
sr.release()
275-
return opts
276-
}
277-
278-
// WithRemoteParentFromLocalSpan is equivalent to
279-
// WithRemoteParentFromSpanMeta(sp.Meta()), but doesn't allocate. The span will
280-
// be created with parent info, but without being linked into the parent. This
281-
// is useful when the child needs to be created with a different Tracer than the
282-
// parent - e.g. when a tenant is calling into the local KV server.
283-
func WithRemoteParentFromLocalSpan(sp *Span) SpanOption {
284-
ref, _ /* ok */ := tryMakeSpanRef(sp)
285-
// Note that ref will be Empty if tryMakeSpanRef() failed. In that case, the
286-
// resulting span will not have a parent.
287-
return remoteParentFromLocalSpanOption(ref)
288-
}
289-
290269
type remoteParentFromTraceInfoOpt tracingpb.TraceInfo
291270

292271
var _ SpanOption = &remoteParentFromTraceInfoOpt{}

0 commit comments

Comments
 (0)