Open
Conversation
Allow SpanRefinement to specify an optional `name: SpanName` field that overrides the `name.note` from the referenced base span. This enables provider-specific span name formats as described in conventions like GenAI. Agent-Logs-Url: https://github.com/open-telemetry/weaver/sessions/ad40e493-8bd6-4a7a-824f-22b6ac4a00bb Co-authored-by: lmolkova <2347409+lmolkova@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Add SpanRefinement to override name.note in definition
Add optional May 3, 2026
name field to SpanRefinement
Member
|
@copilot go fix ci errors |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #1403 +/- ##
=======================================
- Coverage 82.4% 82.4% -0.1%
=======================================
Files 120 120
Lines 10092 10092
=======================================
- Hits 8320 8319 -1
- Misses 1772 1773 +1 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
Agent-Logs-Url: https://github.com/open-telemetry/weaver/sessions/fdc0a373-ffcf-4622-9417-984bbdc5dc62 Co-authored-by: lmolkova <2347409+lmolkova@users.noreply.github.com>
Contributor
Author
lmolkova
approved these changes
May 3, 2026
lmolkova
reviewed
May 3, 2026
Agent-Logs-Url: https://github.com/open-telemetry/weaver/sessions/a04155c1-2bb9-498b-ad2b-bba738f2dbc2 Co-authored-by: lmolkova <2347409+lmolkova@users.noreply.github.com>
lmolkova
reviewed
May 3, 2026
…schema Agent-Logs-Url: https://github.com/open-telemetry/weaver/sessions/62434a1a-9c2b-4759-8e55-c0dfccff446c Co-authored-by: lmolkova <2347409+lmolkova@users.noreply.github.com>
lmolkova
approved these changes
May 3, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
SpanRefinementcannot override thenamestructure from its base span, preventing provider-specific span name formats (e.g., GenAI conventions that explicitly allow individual systems to specify different span name formats).Changes
crates/weaver_semconv/src/v2/span.rs: Addname: Option<SpanName>toSpanRefinement, with serde skip-if-none. Added tests for parsing with and without the field.schemas/semconv-syntax.v2.md: Document the new optionalnameproperty inspan_refinementsdefinition.schemas/semconv.schema.v2.json: Regenerated JSON schema to include the new optionalnamefield.Usage
Resolution: if the refinement sets
name, the entirenamestructure replaces the base span'sname; otherwise, the base span'snameis inherited. The resolved schema and forge crates already propagatenamethrough their flattenedSpanstruct, so no changes needed there.