opencensus-go
opencensus-go copied to clipboard
provide better documentation of tags
I don't quite get tags. Are they similar to prometheus labels? Do they work with traces? Or only stats? How are they match existing exporter nomenclature?
The documentation states:
Tags provide additional cardinality to the OpenCensus instrumentation data.
I use Stackdriver and tried adding a few tags to my trace context, but had no way to see this data in my GCP trace view. Turns out they're called "Labels" in stackdriver and labels are populated using the trace. SetSpanAttributes
function.
Better documentation on tags as well as how various Census concepts relate to existing exporters would help a lot.
Thanks for the feedback. Tags are not related to traces, they are related to stats. For example they turn into Prometheus labels. Span attributes / Stackdriver trace labels are a totally different thing.
Agree that each exporter should document the mapping from Census concepts to backend that they implement.
/cc @bogdandrutu
We should also determine whether we want to apply the tags as attributes on spans.
+1 this is confusing! I thought that OpenCensus tags were passed as Datadog APM Trace metadata, but OpenCensus attributes are actually the key-values that are passed as Datadog APM Trace metadata.
This is further confusing because the OpenCensus Datadog exporter calls its metadata tags
in the library:
https://github.com/DataDog/opencensus-go-exporter-datadog/blob/2bef335f5ffffcfa296102765c21882a9158e52a/span.go#L81-L83
/cc @bogdandrutu
We should also determine whether we want to apply the tags as attributes on spans.
Has there been further discussion of this?