Skip to content

feat(instrumentation-aiohttp-client): Add support for HTTP metrics #3517

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

Merged
merged 11 commits into from
May 27, 2025

Conversation

hectorhdzg
Copy link
Member

@hectorhdzg hectorhdzg commented May 19, 2025

Description

Added support for metrics in aiohttp-client instrumentation

Fixes #3516

Type of change

Please delete options that are not relevant.

  • New feature (non-breaking change which adds functionality)

How Has This Been Tested?

Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration

  • Unit tests

Does This PR Require a Core Repo Change?

  • No.

Checklist:

See contributing.md for styleguide, changelog guidelines, and more.

  • Followed the style guidelines of this project
  • Changelogs have been updated
  • Unit tests have been added
  • Documentation has been updated

@hectorhdzg hectorhdzg requested a review from a team as a code owner May 19, 2025 22:33
Copy link
Contributor

@tammy-baylis-swi tammy-baylis-swi left a comment

Choose a reason for hiding this comment

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

This lgtm; thanks for tests, docstring updates, and consistency with how other instrumentors handle the semconv opt-in.

Would be good to also get other Approver and Maintainer eyes on this.

Copy link
Member

@emdneto emdneto left a comment

Choose a reason for hiding this comment

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

Thanks! I left some changes that I think we should do to not back into this later.
See #3220 for more context

hectorhdzg and others added 5 commits May 21, 2025 16:05
…rc/opentelemetry/instrumentation/aiohttp_client/__init__.py

Co-authored-by: Emídio Neto <[email protected]>
…rc/opentelemetry/instrumentation/aiohttp_client/__init__.py

Co-authored-by: Emídio Neto <[email protected]>
…rc/opentelemetry/instrumentation/aiohttp_client/__init__.py

Co-authored-by: Emídio Neto <[email protected]>
Copy link
Member

@emdneto emdneto left a comment

Choose a reason for hiding this comment

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

I'm missing the SERVER_ADDRESS and SERVER_PORT in labels for the duration_histogram_new. They are required. can we set them?

@hectorhdzg
Copy link
Member Author

I'm missing the SERVER_ADDRESS and SERVER_PORT in labels for the duration_histogram_new. They are required. can we set them?

@emdneto the attributes were missing in Spans as well, added both

@emdneto
Copy link
Member

emdneto commented May 26, 2025

I'm missing the SERVER_ADDRESS and SERVER_PORT in labels for the duration_histogram_new. They are required. can we set them?

@emdneto the attributes were missing in Spans as well, added both

oh. Awesome! Thank you

@xrmx xrmx enabled auto-merge (squash) May 27, 2025 20:38
@xrmx xrmx merged commit a912c9e into open-telemetry:main May 27, 2025
625 checks passed
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.

Metrics instrumentation aiohttp client
4 participants