-
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
Define attribute requirement levels #2522
Define attribute requirement levels #2522
Conversation
d1dd0d9
to
b9a95b0
Compare
a99c9d9
to
1278f24
Compare
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.
LGTM.
Generally looks very sensible to me 👍, my only concern is about the MUST for transforming conditional/recommended into opt-in. |
c2929e9
to
ab1d94a
Compare
Overall LGTM - let's address @tigrannajaryan concern though. Maybe we can discuss it in today's Spec call? |
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.
@lmolkova Thank you for writing this PR. I think this is very important and we need to have it in the spec.
It has a big impact on all conventions and implementations, so please bear with me, I want to make sure the language is clear and precise enough in this section.
I think the PR now reads much better, there are only a few questions remaining that would be great to clarify before merging. Sorry for lots of comments :-)
I would also like to understand what others think about MUST vs SHOULD for the Required level.
Summary of the SIG discussion:
Bogdan's feedback:
Bogdan's questions:
|
Interesting. I didn't know RFC defines "REQUIRED". I agree with this. Once the new level definitions are accepted we will need to review all existing semantic conventions to make sure we don't unnecessarily use REQUIRED level. |
74e24ca
to
6f57605
Compare
How would everyone feel about
The summary is mostly correct, but not full:
Considering these nuances RFC levels would not be descriptive enough. |
@tigrannajaryan and @bogdandrutu I went through the existing semantic conventions (ones we have YAML for) and here's what I believe this change would mean for them: We have 26
I believe new terminology does not change semantics for them. We have 26
So I believe this is a pretty minor change for current conventions and we already have good classification there, just some lack of terminology. |
+1
+1 I like the name.
The RFC defines "recommended" as "should", without any caveat like "unless disabled". Are we mixing 2 "dimensions" here: 1. for devs to make enough effort to make these available in the instrumentation; 2. the capability for users of enabling/disabling these? I would actually consider to change "Opt-In" to "OPTIONAL", and say that instrumentation plugins must offers way to "opt-out" for any recommended attributes, and to "opt-in' for any available "optional" attributes. the required and conditional required cannot be disabled, this way we separate the 2 concerns about what is available and what is configurable for the user.
I agree, but I would use references to RFC when explain them, since is easier to understand. |
e3e6c9c
to
cd16071
Compare
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.
LGTM, great job.
I left some minor spelling comments.
Co-authored-by: Tigran Najaryan <[email protected]>
Co-authored-by: Christian Neumüller <[email protected]>
4eb2e4e
to
0259a97
Compare
0259a97
to
8a8b034
Compare
1acb891
to
8434c04
Compare
@lmolkova please resolve the conflicts. |
@tigrannajaryan done, thank you! |
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.
This is super valuable work, thankyou for getting this through!
* nits * review comments * No exceptions for Required attributes, clarifications on performance * Conditional clarifications * nits * Conditional -> required conditionally and minor fixes * Align requirement levels with RFC levels better * Clarify Note on required attributes * Update specification/common/attribute-requirement-level.md Co-authored-by: Tigran Najaryan <[email protected]> * Clarify Note on required attributes * Remove performance from conditionally required attributes * Clarify Conditionally Required case when condition is false * Apply suggestions from code review Co-authored-by: Tigran Najaryan <[email protected]> * Apply suggestions from code review Co-authored-by: Christian Neumüller <[email protected]> * headings for levels and moving things around * nits: formatting Co-authored-by: Tigran Najaryan <[email protected]> Co-authored-by: Christian Neumüller <[email protected]> Co-authored-by: Reiley Yang <[email protected]>
* nits * review comments * No exceptions for Required attributes, clarifications on performance * Conditional clarifications * nits * Conditional -> required conditionally and minor fixes * Align requirement levels with RFC levels better * Clarify Note on required attributes * Update specification/common/attribute-requirement-level.md Co-authored-by: Tigran Najaryan <[email protected]> * Clarify Note on required attributes * Remove performance from conditionally required attributes * Clarify Conditionally Required case when condition is false * Apply suggestions from code review Co-authored-by: Tigran Najaryan <[email protected]> * Apply suggestions from code review Co-authored-by: Christian Neumüller <[email protected]> * headings for levels and moving things around * nits: formatting Co-authored-by: Tigran Najaryan <[email protected]> Co-authored-by: Christian Neumüller <[email protected]> Co-authored-by: Reiley Yang <[email protected]>
Extracted general attribute requirement level from #2469
Changes
Adds terminology to be used by semantic convention to declare attribute presence requirements.
We currently have 4 vaguely defined levels across semantic conventions:
always
- all instrumentations MUST provideconditional
which we use to specify when an attribute should be provided (but we use it inconsistently on optional and required attributes)e.g. rpc.service is recommended (but not required?)
or http.retry_count that is optional and conditional
or db.name which is required if available
none, which means optional
requires explicit enablement (e.g. HTTP headers)
This PR adds and clarifies the terminology:
required
- MUST provideconditional
(naming suggestions are welcome)conditionally required
- MUST IF <condition>recommended
- SHOULD provideopt-in
optional
- MAY provide (when enabled)Here's the corresponding tooling change: open-telemetry/build-tools#92
Related issues #2114.