Skip to content

Use canonical name for aiohttp request span name#3896

Merged
xrmx merged 15 commits into
open-telemetry:mainfrom
krnr:aiohttp-server
Apr 23, 2026
Merged

Use canonical name for aiohttp request span name#3896
xrmx merged 15 commits into
open-telemetry:mainfrom
krnr:aiohttp-server

Conversation

@krnr

@krnr krnr commented Oct 25, 2025

Copy link
Copy Markdown
Contributor

Description

Current implementation doesn't use canonical attribute of a Resource, which leads to the situation when generated spans all have unique names. It creates high cardinality of spans. Other frameworks that use path params create spans with "canonical" paths in names (e.g. fastapi [1] )

Type of change

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

How Has This Been Tested?

add a new unit test:

  • test_url_params_instrumentation

Does This PR Require a Core Repo Change?

  • Yes. - Link to PR:
  • 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

@krnr krnr requested a review from a team as a code owner October 25, 2025 05:15
@linux-foundation-easycla

linux-foundation-easycla Bot commented Oct 25, 2025

Copy link
Copy Markdown

CLA Signed

The committers listed above are authorized under a signed CLA.

@krnr krnr force-pushed the main branch 5 times, most recently from 1ba9a1c to 8689cfc Compare October 25, 2025 05:29

@bisgaard-itis bisgaard-itis left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Looks good. Thanks a lot for the effort! 👍🏻

@xrmx xrmx moved this to Reviewed PRs that need fixes in Python PR digest Oct 31, 2025
@krnr krnr force-pushed the aiohttp-server branch 2 times, most recently from c05f041 to 3bb8b84 Compare November 5, 2025 20:14
Comment thread CHANGELOG.md Outdated
@krnr krnr force-pushed the aiohttp-server branch 2 times, most recently from 5f4116a to 32ccac9 Compare November 8, 2025 07:46
@tammy-baylis-swi tammy-baylis-swi requested a review from a team November 10, 2025 17:23

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

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Thank you @krnr for this. Lgtm though I want some other Approvers to have a look at this change.

If you wanted to bring this up more synchronously, please feel welcome to join the Python SIG meeting on Zoom on Thursdays -- Calendar with links here. Else this PR should still be visible on the PR digest board.

@tammy-baylis-swi tammy-baylis-swi moved this from Reviewed PRs that need fixes to Ready for review in Python PR digest Nov 10, 2025
…rc/opentelemetry/instrumentation/aiohttp_server/__init__.py

Co-authored-by: Tammy Baylis <96076570+tammy-baylis-swi@users.noreply.github.com>
Comment thread CHANGELOG.md Outdated
@xrmx xrmx moved this from Ready for review to Reviewed PRs that need fixes in Python PR digest Nov 20, 2025
@xrmx xrmx self-requested a review November 20, 2025 15:04
@github-actions

github-actions Bot commented Mar 9, 2026

Copy link
Copy Markdown

This PR has been automatically marked as stale because it has not had any activity for 14 days. It will be closed if no further activity occurs within 14 days of this comment.
If you're still working on this, please add a comment or push new commits.

@github-actions github-actions Bot added the Stale label Mar 9, 2026
@tammy-baylis-swi

Copy link
Copy Markdown
Contributor

Hi @xrmx I've just resolved some conflicts. Any other suggestions?

@github-actions

github-actions Bot commented Apr 3, 2026

Copy link
Copy Markdown

This PR has been automatically marked as stale because it has not had any activity for 14 days. It will be closed if no further activity occurs within 14 days of this comment.
If you're still working on this, please add a comment or push new commits.

@github-actions github-actions Bot added the Stale label Apr 3, 2026

@xrmx xrmx left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

precommit is failing

@xrmx xrmx moved this from Reviewed PRs that need fixes to Approved PRs that need fixes in Python PR digest Apr 3, 2026
@github-actions github-actions Bot removed the Stale label Apr 4, 2026
@github-actions

Copy link
Copy Markdown

This PR has been automatically marked as stale because it has not had any activity for 14 days. It will be closed if no further activity occurs within 14 days of this comment.
If you're still working on this, please add a comment or push new commits.

@github-actions github-actions Bot added the Stale label Apr 23, 2026
@xrmx xrmx enabled auto-merge (squash) April 23, 2026 07:30
@xrmx xrmx merged commit 2caa924 into open-telemetry:main Apr 23, 2026
751 checks passed
@github-project-automation github-project-automation Bot moved this from Approved PRs that need fixes to Done in Python PR digest Apr 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

5 participants