Exemplar: revert wrong implementation.#1067
Exemplar: revert wrong implementation.#1067songy23 merged 4 commits intocensus-instrumentation:masterfrom
Conversation
bogdandrutu
left a comment
There was a problem hiding this comment.
Happy to review more PRs to fix this.
trace/exemplar.go
Outdated
|
|
||
| func init() { | ||
| exemplar.RegisterAttachmentExtractor(attachSpanContext) | ||
| metricdata.RegisterAttachmentExtractor(attachSpanContext) |
There was a problem hiding this comment.
We need to cleanup these things as well probably. Don't really understand why we need this.
There was a problem hiding this comment.
Agree trace or tag shouldn't depend on exemplar. I removed AttachmentExtractor for now.
tag/context.go
Outdated
|
|
||
| func init() { | ||
| exemplar.RegisterAttachmentExtractor(extractTagsAttachments) | ||
| metricdata.RegisterAttachmentExtractor(extractTagsAttachments) |
There was a problem hiding this comment.
This is a wrong usage of exemplars, tags are not "exemplars"
60c842a to
8ab21ab
Compare
|
Will this be a breaking change? |
|
This is a breaking change to those who import "go.opencensus.io/exemplar". Though I don't believe any user would be using the previous exemplar APIs since no backend supports it before. For |
|
This PR is only doing cleanups. More PRs will follow on refactoring the exemplar APIs. |
|
@songy23 @rghetia This also breaks |
|
please see suggestion for solution in census-ecosystem/opencensus-go-exporter-ocagent#49 |
|
Sorry for the trouble, I wasn't aware that there're downstream libraries depending on this. #1071 should fix it temporarily, meanwhile please migrate to the new package like census-ecosystem/opencensus-go-exporter-ocagent#49. |
* Exemplar: move to metricdata. * Remove AttachmentExtractor. * More cleanup. * Add a TODO for next PR. (cherry picked from commit 604812a)
Updates #1058.
Java counterpart: census-instrumentation/opencensus-java#1791. The first step on refactoring exemplar APIs. More PRs will follow.