Skip to content

[Metrics API] Simplify public API contract of instruments for SDK#2207

Merged
cijothomas merged 5 commits intoopen-telemetry:mainfrom
utpilla:utpilla/Simplify-public-API-for-SDK
Oct 14, 2024
Merged

[Metrics API] Simplify public API contract of instruments for SDK#2207
cijothomas merged 5 commits intoopen-telemetry:mainfrom
utpilla:utpilla/Simplify-public-API-for-SDK

Conversation

@utpilla
Copy link
Contributor

@utpilla utpilla commented Oct 13, 2024

Changes

  • All the synchronous instruments can utilize a single trait instead of having dedicated traits such as SyncCounter, SyncGauge, SyncHistogram etc.
  • This PR introduces a single trait SyncInstrument which all the synchronous instruments can use
  • This also reduces the number of public APIs exposed

Please provide a brief description of the changes here.

Merge requirement checklist

  • CONTRIBUTING guidelines followed
  • Appropriate CHANGELOG.md files updated for non-trivial, user-facing changes

@utpilla utpilla requested a review from a team as a code owner October 13, 2024 17:26
@codecov
Copy link

codecov bot commented Oct 13, 2024

Codecov Report

Attention: Patch coverage is 90.90909% with 1 line in your changes missing coverage. Please review.

Project coverage is 79.0%. Comparing base (c5cfa40) to head (5aec607).
Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
opentelemetry/src/metrics/noop.rs 0.0% 1 Missing ⚠️
Additional details and impacted files
@@          Coverage Diff          @@
##            main   #2207   +/-   ##
=====================================
  Coverage   79.0%   79.0%           
=====================================
  Files        122     122           
  Lines      21086   21056   -30     
=====================================
- Hits       16672   16651   -21     
+ Misses      4414    4405    -9     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Member

@cijothomas cijothomas left a comment

Choose a reason for hiding this comment

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

Nice!

@cijothomas cijothomas merged commit 42685e8 into open-telemetry:main Oct 14, 2024
takumi-earth pushed a commit to earthlings-dev/opentelemetry-rust that referenced this pull request Jan 27, 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