-
Notifications
You must be signed in to change notification settings - Fork 933
[Blocked] Add empty value attribute #4595
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
Conversation
|
CC @open-telemetry/go-maintainers |
Co-authored-by: Tyler Yahn <[email protected]>
specification/common/README.md
Outdated
| external log APIs, which do not necessarily have the same value type | ||
| restrictions as the standard attribute definition. | ||
|
|
||
| Note: Extending the set of standard attribute value types is a breaking change. |
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.
I think we need to start with proto changes and replace comments like https://github.com/open-telemetry/opentelemetry-proto/blob/be5d58470429d0255ffdd49491f0815a3a63d6ef/opentelemetry/proto/trace/v1/trace.proto#L209-L213
// The OpenTelemetry API specification further restricts the allowed value types:
// https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/common/README.md#attribute
// Attribute keys MUST be unique (it is not allowed to have more than one
// attribute with the same key).
we probably need to replace it with comment that they are going to be allowed in 6 months
opentelemetry-specification/oteps/4485-extending-attributes-to-support-complex-values.md
Lines 111 to 112 in 8aa1d27
| - Stable exporters will be prohibited from emitting complex attributes by default on signals | |
| other than Logs until at least 6 months after this OTEP is merged. |
Or, at least, leave a note here that complex attributes are coming and their support is in development, nobody should stabilize them in the next 6 month.
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.
we probably need to replace it with comment that they are going to be allowed in 6 months
I feel like this is an orthogonal PR given the changes of https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/common/README.md#attribute are marked with Development status.
Moreover, this PR does not make the existing comment invalid and should block this PR.
Therefore, I think a PR in proto repo can be done in parallel.
I am not sure how we want to update the comment in proto repo as of today.
Are you able to help with it?
EDIT: I tried to come up with a PR in the proto repo. PTAL:
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.
As discussed in the SIG meeting, we agreed to reintroduce this "note" in this PR, since it’s clearer to handle the broader change in a separate PR. That separate PR will:
- communicate that we’ve revised the decision and will now allow the addition of new attribute types (which is not considered a major change),
- clarify that introducing new attribute types will require a minor version bump in the OTLP (proto) repository.
This PR will be blocked until that separate PR is merged.
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.
I created #4602 for tracking.
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, can you please block this PR (request changes) with e.g. following comment:
Blocked by:
- https://github.com/open-telemetry/opentelemetry-specification/issues/4602so that it is not accidentally merged?
|
This PR was marked stale due to lack of activity. It will be closed in 7 days. |
|
This PR was marked stale due to lack of activity. It will be closed in 7 days. |
|
This PR was marked stale due to lack of activity. It will be closed in 7 days. |
|
This PR was marked stale due to lack of activity. It will be closed in 7 days. |
|
Looks like this addresses #4392, but maybe some of the concerns like a |
|
I prefer to go forward with #4651 instead of this one (to hopefully move a little faster). |
Blocked by:
Related OTEP: https://github.com/open-telemetry/opentelemetry-specification/blob/main/oteps/4485-extending-attributes-to-support-complex-values.md
To be precise:
opentelemetry-specification/oteps/4485-extending-attributes-to-support-complex-values.md
Lines 40 to 48 in 8aa1d27
It is also worth mentioning that it is already allowed by OTLP:
Prototype:
Also fixes #4468
as it removes the portion which said that extending the attribute types is a breaking change as it was already approved via #4485.
This is necessary to be able to represent an empty (that is the default) Log Record Body using "Standard Attributes".
This is needed towards stabilization of OTel Go Logs API and SDK (we need it "stable" though; not only "development"); more:
I also checked the stable Logs API implementations (according to https://opentelemetry.io/status) and none of them seem to be strictly compliant with the specification in regards of Log Record Body value:
StringorValue<T>which does not support setting an empty value: https://github.com/open-telemetry/opentelemetry-java/blob/dc2874e2fa4696bf15c31ae60644bac2dfc546b9/api/all/src/main/java/io/opentelemetry/api/logs/LogRecordBuilder.java#L76-L91; therefore I think this change would be also very welcome for OTel Java, CC @open-telemetry/java-approversstring?: https://github.com/open-telemetry/opentelemetry-dotnet/blob/361a1655b9ac239b88fbd7ae51048ec9066774d9/src/OpenTelemetry/Logs/LogRecord.cs#L251