Skip to content

Fix/change some messaging attributes to match conventions #1624

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

Closed
wants to merge 6 commits into from

Conversation

s22su
Copy link

@s22su s22su commented Apr 3, 2024

I used opentelemetry-semantic_conventions in one of my projects and noticed that some attributes are different from the docs on following pages:

All kafka attributes described in docs are present in opentelemetry-semantic_conventions gem now.
Messaging batch count is added because I wat to use it in my code and it was missing before.

s22su added 6 commits April 3, 2024 09:49
According to docs [here][1] it should be `consumer.group` instead of
snake_case `consumer_group`.

[1]: https://opentelemetry.io/docs/specs/semconv/messaging/kafka/#span-attributes
According to docs [here][1] it should be `message.key` instead of
snake_case `message_key`.

[1]: https://opentelemetry.io/docs/specs/semconv/messaging/kafka/#span-attributes
There is already `messaging.kafka.partition`, but [docs][1] have
`messaging.kafka.destination.partition` instead. I currently kept the
old attribute for backwards compatibility.

[1]: https://opentelemetry.io/docs/specs/semconv/messaging/kafka/#span-attributes
Copy link

linux-foundation-easycla bot commented Apr 3, 2024

CLA Signed


The committers listed above are authorized under a signed CLA.

@kaylareopelle
Copy link
Contributor

👋 Hi @s22su! Thank you for your contribution!

I'm not sure about the exact status of the semantic conventions gem right now. The approvers/maintainers spoke in January about wanting to rework it. I'll bring your PR up during the SIG meeting tomorrow and try to get some next steps.

@s22su
Copy link
Author

s22su commented Apr 16, 2024

@kaylareopelle do you have any updates on this?

@kaylareopelle
Copy link
Contributor

Hi @s22su, I'm sorry for taking so long to get back to you on this.

Our approach to semantic conventions is in flux. Our current approach is brittle for a number of reasons, including we don't have a great way to handle removals of constants without potentially breaking things for users upstream.

We're grateful that you pointed out the changes in the messaging conventions and opened this PR. Your PR reinvigorated our discussion about #1567, opened by @robbkidd. This PR presents an alternate approach for the semantic conventions gem.

As an alternative to your PR, we'd like to update the messaging conventions portion of #1567 to include the latest content.

Would you be willing to test out that PR, once we've updated it, to see if it works in your environment?

@s22su
Copy link
Author

s22su commented Apr 26, 2024

@kaylareopelle it seems to me like the intended usage of the gem after linked PR is merged, will be to update opentelemetry-semantic_conventions gem version (I believe it will be a major version bump) and use OpenTelemetry::SemanticConventions_1_20_0::Trace::MESSAGING_KAFKA_MESSAGE_KEY instead of OpenTelemetry::SemanticConventions::Trace::MESSAGING_KAFKA_MESSAGE_KEY so not sure what is there is to test.

When next version will be released I'll happily use it in our internal library. Feel free to close this PR, I'll keep an eye on #1567 to know when I can update.

@kaylareopelle
Copy link
Contributor

Thanks for your understanding, @s22su.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants