Skip to content

Conversation

thompson-tomo
Copy link
Contributor

@thompson-tomo thompson-tomo commented Aug 9, 2025

Fixes #2601

Connected PR #2819 split rendering of deprecated

Changes

This introduces upgrade documents which documents how to upgrade the telemetry in that namespace to the latest version. These documents cover both the signals themselves as well as the attributes on the signals. Each change has an upgrade action which is determined based on the depreciation level. 3 factors influence how the action behaves:

  • Deprecation reason ie renamed
  • Instrumentation status ie unstable vs stable
  • Should the change be gradual and user can control it or not.

Note the old attributes are needed to be added for potential code generation as we are needing a way to support side by side.

Note: if the PR is touching an area that is not listed in the existing areas, or the area does not have sufficient domain experts coverage, the PR might be tagged as experts needed and move slowly until experts are identified.

Merge requirement checklist

  • CONTRIBUTING.md guidelines followed.
  • Change log entry added, according to the guidelines in When to add a changelog entry.
    • If your PR does not need a change log, start the PR title with [chore]
  • Links to the prototypes or existing instrumentations (when adding or changing conventions)

@thompson-tomo thompson-tomo requested review from a team as code owners August 9, 2025 05:02
@thompson-tomo thompson-tomo changed the title [chore] Introduce additional requirement levels #2601 Introduce additional requirement levels #2601 Aug 9, 2025
@github-project-automation github-project-automation bot moved this to V1 - Stable Semantics in Spec: Messaging Semantics Aug 9, 2025
@thompson-tomo thompson-tomo force-pushed the chore/#2601_IntroduceAdditionalRequirementLevels branch from 67f2f00 to c1e6f46 Compare August 9, 2025 05:25
@thompson-tomo thompson-tomo changed the title Introduce additional requirement levels #2601 Introduce additional attribute requirement levels #2601 Aug 9, 2025
@thompson-tomo thompson-tomo force-pushed the chore/#2601_IntroduceAdditionalRequirementLevels branch from a240fa4 to f43abc8 Compare August 10, 2025 01:43
These should therefore only be enabled explicitly by a user making an informed
decision.

## Migrate
Copy link
Contributor

Choose a reason for hiding this comment

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

This is an interesting concept. I believe we were more thinking for things like this there would be a "major version release" that would have its own sub-migration, vs piecemeal / fine-grained migration.

Curious what other @open-telemetry/specs-semconv-maintainers + @open-telemetry/weaver-maintainers think there.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

This approach focuses on improving the rendering of deprecated attributes by explaining what to do with them but more significantly reduces the ambiguity in the current solution. You could still have tagged releases with sub-migration.

Copy link
Member

@lmolkova lmolkova Aug 22, 2025

Choose a reason for hiding this comment

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

it does not look like a real requirement level - it does not appear in the yaml schema and is not visible to code generation. I don't suggest to make it a requirement level though.

The goal seems to be to

  • render a 'past' version of conventions
  • provide migration instructions

That's what we're trying to do with migration guides.

I'd be happy to see them automated (it's possible now) and separate from the general conventions which tell how telemetry should look following the current version and nothing else.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Ok, based on that feedback i have changed it from a requirement level to a deprecation action which is now rendered in a separate table and requirement levels are not being touched.

The goal is to provide a single spot for a user to go to get an explaination of the attributes on their traces, metrics etc without needing to jump through many different documents. It can be used by new contributors to oss projects to know quickly know which attributes are from the spec and which one's have been added by other developers not following the spec.

It also helps to address the ambguity in how to update the signal definition being emitted when wanting to follow the published guidance which is especially important when the definitions being updated to are still not stable. Hence the clear definition of the actions.

As it currently stands if you were wanting to update an elasticsearch instrumentation to the latest spec from pre < 1.20 you end up in a massive grey area as:

  • the migration guide says the OTEL_SEMCONV_STABILITY_OPT_IN variable is only when migrating to stable,
  • the elasticsearch page has no warning on it and is defined as experimental,
  • the database span page has a warning that you need the variable if upgrading from <= 1.24 so you could upgrade to 1.25 (also not stable) using the variable for the changed attributes but that introduces new grey area. Then any subsequent updates if not changing to a stable definition you don't need the stability opt in variable to control them.

With the approach here you can see which attributes need to be controlled via the stability environment variable, which one's dont and how the instrumentation stability impacts the behaviour.

The migration guide seems alot more like a changelog/revision history when you read it.

Copy link
Member

@lmolkova lmolkova Aug 25, 2025

Choose a reason for hiding this comment

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

we can shape migration guides to provide any details.

with this proposal, we'd have more confusion:

  • current and previous versions of semconv in the same page
  • all previous versions squashed together into 'past attributes'
  • no details on non-attribute parts of the past versions.

I don't see how it reduces any ambiguity around elasticsearch - it does not even change anything on its page. If there is a problem there, we better address it first without introducing new notions.

With current state in main:

  • users can check past version via tags, e.g. https://github.com/open-telemetry/semantic-conventions/tree/v1.36.0. They should have schema-url in their telemetry to tell them which version they are in
  • users can check the current version on main
  • they can read the migration guide to learn how to get from version vPast to vCurrent and explore which attributes were used by the conventions in the past.

What I'm still suggesting is to build a better vision on what's included in the migration guides and automate their generation instead of squashing them into one page in actual conventions.

I would support adding a link to migration guide from the 'actual' semconv page

Copy link
Contributor Author

Choose a reason for hiding this comment

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

No where has it been stated by me that this would remove the migration guides, in fact I stated you could still have them.

all previous versions squashed together into 'past attributes'

This is No different to what you have now in migration guide for db for example.

no details on non-attribute parts of the past versions.

Migration Guide could & would still exist to cover those additional things.

I don't see how it reduces any ambiguity around elasticsearch - it does not even change anything on its page.

That's because the signals don't currently contain the past attributes which would need for codegen etc. Once they are added to the model, the docs get updated. I have only added a couple of attributes to verify it

If there is a problem there, we better address it first without introducing new notions.

It is a general problem which can be reproduced across the conventions and not restricted to the db namespace, but also applies to messaging etc.

They should have schema-url in their telemetry to tell them which version they are in

I have never encountered the schema-url being set in the implementations i have seen.

What I'm still suggesting is to build a better vision on what's included in the migration guides and automate their generation instead of squashing them into one page in actual conventions.

I agree with automating and improving the migration guides but I don't see it as an either or scenario but rather they complement each other. As such I would like to see both of them with the deprecation actions also appearing in the migration guides as a way to describe how to make the upgrade as that is where the grey area is.

@thompson-tomo thompson-tomo force-pushed the chore/#2601_IntroduceAdditionalRequirementLevels branch 4 times, most recently from be902ba to e5a739b Compare August 23, 2025 06:17
@thompson-tomo thompson-tomo changed the title Introduce additional attribute requirement levels #2601 Introduce attribute deprecation actions #2601 Aug 23, 2025
@thompson-tomo thompson-tomo force-pushed the chore/#2601_IntroduceAdditionalRequirementLevels branch 2 times, most recently from 92e2325 to a7453b5 Compare August 23, 2025 07:45
@thompson-tomo thompson-tomo force-pushed the chore/#2601_IntroduceAdditionalRequirementLevels branch 3 times, most recently from b13df43 to bff4835 Compare August 24, 2025 03:08
@thompson-tomo thompson-tomo force-pushed the chore/#2601_IntroduceAdditionalRequirementLevels branch from bff4835 to 17e7051 Compare August 28, 2025 02:54
Copy link

This PR was marked stale due to lack of activity. It will be closed in 7 days.

@github-actions github-actions bot added the Stale label Sep 12, 2025
@thompson-tomo thompson-tomo force-pushed the chore/#2601_IntroduceAdditionalRequirementLevels branch from 17e7051 to 31aa4cc Compare September 17, 2025 04:16
@thompson-tomo thompson-tomo force-pushed the chore/#2601_IntroduceAdditionalRequirementLevels branch from 31aa4cc to 2abc7e5 Compare September 17, 2025 04:29
@github-actions github-actions bot removed the Stale label Sep 18, 2025
@thompson-tomo thompson-tomo marked this pull request as draft September 27, 2025 07:10
@thompson-tomo thompson-tomo force-pushed the chore/#2601_IntroduceAdditionalRequirementLevels branch from 406ff8d to 05c8498 Compare September 27, 2025 10:33
@thompson-tomo thompson-tomo changed the title Introduce attribute deprecation actions #2601 Generate upgrade document based on deprecations #2601 Sep 27, 2025
@thompson-tomo thompson-tomo force-pushed the chore/#2601_IntroduceAdditionalRequirementLevels branch from 05c8498 to 5170024 Compare September 28, 2025 05:13
@thompson-tomo thompson-tomo force-pushed the chore/#2601_IntroduceAdditionalRequirementLevels branch from 5170024 to 777a83c Compare September 28, 2025 05:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: V1 - Stable Semantics
Development

Successfully merging this pull request may close these issues.

Improve consistency in migrating to new semconv
4 participants