Skip to content
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

Fix unit in system metrics #2922

Merged
merged 2 commits into from
Oct 25, 2024
Merged

Fix unit in system metrics #2922

merged 2 commits into from
Oct 25, 2024

Conversation

bjrara
Copy link
Contributor

@bjrara bjrara commented Oct 22, 2024

Description

Convert system metric to use UCUM to follow OpenTelemetry semantic conventions

Type of change

Please delete options that are not relevant.

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update

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

  • Test A

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

@xrmx
Copy link
Contributor

xrmx commented Oct 23, 2024

It can't hurt I guess, but aren't the names of the metrics out of spec?

@xrmx
Copy link
Contributor

xrmx commented Oct 23, 2024

There is at least another "bytes" usage, please update that too

@bjrara bjrara requested a review from a team as a code owner October 23, 2024 18:16
@bjrara
Copy link
Contributor Author

bjrara commented Oct 23, 2024

There is at least another "bytes" usage, please update that too

Fixed it. Thank you!

@bjrara
Copy link
Contributor Author

bjrara commented Oct 23, 2024

It can't hurt I guess, but aren't the names of the metrics out of spec?

They aren't. But I guess this is the legacy we will need to carry until we find a deprecation path. For metric units fixes, I believe it is a reasonable change because the OTEL dependency services won't expect the units as bytes or seconds since it doesn't conform to the convention.

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.

LGTM since we are not changing metric names, but worried about this comment in semconv:

>SHOULD NOT adopt any breaking changes from document until the system semantic conventions are marked stable. Conventions include, but are not limited to, attributes, metric names, and unit of measure.

We are including unit of measure changes

@lzchen lzchen merged commit 779ec9e into open-telemetry:main Oct 25, 2024
536 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.

4 participants