Skip to content
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

Support Elastic Cloud OpenTelemetry attributes #154

Merged
merged 3 commits into from
Mar 13, 2024

Conversation

pquentin
Copy link
Member

Relates elastic/elasticsearch-py#2435, and builds on #153.

Since we only get the headers after the request is finished, the context manager now yields a OpenTelemetrySpan class that can be used to set attributes. I use it here to set specific Elastic Cloud attributes and will use it in each HTTP implementation to set url.full, server.address and server.port .

@pquentin pquentin requested a review from xrmx March 12, 2024 15:07
@pquentin pquentin changed the title Set OpenTelemetry db.operation attribute Support Elastic Cloud OpenTelemetry attributes Mar 12, 2024
Copy link
Member

@xrmx xrmx left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me, metadata matches upstream semantic conventions

@pquentin pquentin merged commit 4c15f79 into elastic:main Mar 13, 2024
10 checks passed
@pquentin pquentin deleted the elastic-cloud-otel-attributes branch March 13, 2024 07:17
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.

None yet

2 participants