support some sort of span link
c-cube opened this issue · 2 comments
A span (implicit or explicit) should be causally linkable to another span (or multiple other spans), either at creation time or with add_data_to_span
. E.g. add ?link_to:span list -> …
to add_data_to_span
and span creation functions.
very useful for OTEL and streaming. See https://opentelemetry.io/docs/concepts/signals/traces/#span-links .
Honestly, I'm leaning towards user-data for this — perhaps the best option is to add a `Span span
type to the user-data? instead of a new function?
that leaves exactly what semantics "referring to another span for some reason" has, up to the collector; and allows kinda 'naming' multiple other-related-spans with user-data keys.
Interesting!! I need to think about it, but it's indeed nice to be able to say why you link to another span. Or maybe a list of span (`Span of span list
). Then backends can filter this out, or make it into span links…