-
Notifications
You must be signed in to change notification settings - Fork 888
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Metric SDK specification OUTLINE #347
Metric SDK specification OUTLINE #347
Conversation
The metrics SDK spec should also define how Meter name and version (see Named Tracers and Meters OTEP) should be used and exposed as it does for named tracers here: opentelemetry-specification/specification/sdk-tracing.md Lines 130 to 141 in 724bb54
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice writeup. I left a few comments asking for clarification.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @tigrannajaryan.
@arminru Just to acknowledge your point, I'll say that the current Go SDK does not include any behavior related to named Meters. It implements the provider pattern to get a named Meter, but it currently does not use the name. This is pending work and I intended for this document to track that work, so I haven't included anything about named meters in this document, but you're right that it belongs here. OTOH, the user-facing document does describe the behavior that is expected for named Meters, see here: https://github.com/open-telemetry/opentelemetry-specification/blob/master/specification/api-metrics-user.md#metric-names This requirement is one of the reasons I'm alarmed by the confusion surrounding Named Tracers. If we did not have a "named Meter" concept already in the specification, the metrics API specification has to be extended with some notion of a namespace for metrics, I think. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Solid addition. I left a few comments for small fixes and wondering if we can specify requirements a bit more concretely.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Partial Review
@freeformzSFDC I recommend reviewing the two API specification documents before reviewing this document. See api-metrics.md and api-metrics-user.md. I will try to clarify all the points you raised (tomorrow). Thanks. |
@jmacd I'm not sure if the name of a named meter (i.e., the name of the instrumentation library) is really suitable for namespacing. Should we consider adding a separate namespace parameter? Named meters (tracers) were initially intended for configuration, filtering and troubleshooting. |
@jmacd I read most of those docs. |
@arminru I see your point. I have mixed feelings and am not sure what's the right specification. On the one hand, a named meter can act as a namespace without literally applying the library's name to the metric name in any way. This would imply that two named Meters cannot possibly define the same metric instrument. If two distinctly-named meters defined metrics with the same name, they would be assigned different Descriptors, and the exporter would be left to deal with a name conflict. The solution I had in mind (which I think you're opposed to) is that each descriptor would retain a reference to its Meter's name, and then exporters would be free to apply the namespace in the exporter-appropriate way. (Some systems use '.', some use '_', etc.) On the other hand, we could support an explicit |
@open-telemetry/specs-metrics-approvers As discussed at last week's SIG I have replaced the old draft with an outline. I also wrote a list of terms that will be used. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the outline + terminology looks like a good start. 👍
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The outline looks good.
Left a comment about a possible mismatch between .md file and .png file.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great first step 👍
@bogdandrutu Please approve and merge. |
* WIP: Metric SDK specification * Updates following Tigran's feedback * More rewording * Strengthen requirements for aggregators * Fix typos noted by MrAlias * Address some of freeformzSFDC's feedback * Capitalization * Respond to feedback * Respond to feedback * Handle->Bound instrument * New img * New img ref * Update image * Rename to Differentiator/Integrator * Remove reference to defaultkeys batcher * Batcher->Integrator * Differentiator->Accumulator * Upstream * Move the image * Update image * Simplify the diagram * Remove much dead code * Remove more dead code * Lint * Ignore * Rename metrics SDK * Bold * CheckpointSet -> ExportRecordSet * Update diagram * Update diagram (png) * Editing * Undo
This outlines the components of the current OTel-Go Metric SDK. This is an outline to facilitate breaking the task of writing this specification into smaller tasks.
Part of #626.
Resolves #659.