Skip to content

feat: Add navigation.route.id and adjust pageload and navigation description rules#468

Open
Lms24 wants to merge 1 commit into
mainfrom
lms/feat-attr-desc-add-navigation.route.id
Open

feat: Add navigation.route.id and adjust pageload and navigation description rules#468
Lms24 wants to merge 1 commit into
mainfrom
lms/feat-attr-desc-add-navigation.route.id

Conversation

@Lms24

@Lms24 Lms24 commented Jul 8, 2026

Copy link
Copy Markdown
Member

Some routing frameworks like Vue or React Router, allow giving specific routes custom names/identifiers. For example, the /about route could get name AboutView. Our instrumentation prefers the custom-set names over the parameterized route when it is available and writes that as the span description (transactions) or name (streaming).

This PR adds a new navigation.route.id attribute which will hold the custom route identifier. I decided to avoid the url. namespace because it has nothing to do with a url. There's also http.route but I'm not sure if it would be a better fit (or http.route.id fwiw), since this attribute is mostly used in server-side route handler instrumentation like Express. Therefore I decided to go with navigation.route.id which is used on the client side (and will be used more via #467).

To ensure our span description inference rules map the correct description, this PR also updates the inference rules to prefer the new attribute over url.template.

If reviewers have concerns about the inference rule or the attribute name, I'm happy to change them!

@Lms24 Lms24 requested review from a team, cleptric, mjq and nsdeschenes as code owners July 8, 2026 09:45
@github-actions

github-actions Bot commented Jul 8, 2026

Copy link
Copy Markdown

Semver Impact of This PR

🟡 Minor (new features)

📋 Changelog Preview

This is how your changes will appear in the changelog.
Entries from this PR are highlighted with a left border (blockquote style).


New Features ✨

Attributes

  • Add url.same_origin (deprecated) and http.request.same_origin (replacement) attributes by Lms24 in #456
  • Add db.response.status_code by s1gr1d in #462

Other

  • (ai) Add granular cost attributes for cache and reasoning by vgrozdanic in #461
  • Add navigation.route.id and adjust pageload and navigation description rules by Lms24 in #468

Internal Changes 🔧

  • (ci) Stop inheriting secrets for changelog-preview by tobias-wilfert in #463

🤖 This preview updates automatically when you update the PR.

@Lms24 Lms24 changed the title feat: Add navigation.route.id and use it in description rule feat: Add navigation.route.id and adjust pageload and navigation description rules Jul 8, 2026
@Lms24 Lms24 self-assigned this Jul 8, 2026
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