-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Add support for instrumentation scope attributes during meter/tracer/logger creation #3368
Comments
Similar to #3140, this cannot be added until we have a clear specification for how to export these values. Specifically how conflicts are resolved given these attributes are not identifying. |
I think that
@MrAlias Do you still see these as being blocked by the specification? Is there any existing issue in the specification? Do you have some recommendation on how to proceed/unblock (e.g. where we should define such information)? |
@pellared how will we distinguish between instruments scopes if attributes are added. They are a non-identifying field, they cannot be used in comparisons. How will we resolve duplicate instrument scopes being passed with different attributes. The specification does not say how this is to be resolved. If we make a decision here it will be unspecified and likely to conflict with what the specification ultimately decides. |
From spec
I think we could simply create a type which is like
Trying to solve this here: open-telemetry/opentelemetry-specification#3855 |
How does that resolve the questions quoted? It is adjusting definitions to include logs in instrumentation scope references. The questions already exist for all signal types that use instrument scope. |
Where will |
Sorry, my PR was only about how to solve scope attribute with duplicate keys 🤦
Therefore, I think we should do exactly the same as we do right now when the tracer/logger that have "the same IDs" (return the existing tracer that we have in the map). |
So drop the second set of attributes. Again, I go back to the lack of definition in the specification. That behavior is not defined there. There are "TODO"s in the spec to define the behavior, but there is not stable specification defining it. I do not support implementing a behavior in our implementation that is specifically called out in the specification as something they will decide in the future. Especially since it may ultimately be a different behavior. The last time this was brought up in the SIG meeting this was the SIG consensus as well. |
Thanks. I will try to refine the specification as part of my work for OTel Go Logs. |
I started by creating open-telemetry/opentelemetry-specification#4146 |
open-telemetry/opentelemetry-specification#4160 is merged. |
Problem Statement
Currently, there is no way to define instrumentation scope attributes when creating a tracer/meter as specified in https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/metrics/api.md#get-a-meter
Proposed Solution
Add back instrumentation scope attributes.
Prior Art
This was already implemented by #3132 but it was reverted because specs was not ready yet (#3154).
The text was updated successfully, but these errors were encountered: