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

Refactor metrics to remove MeterSharedState #6845

Merged
merged 1 commit into from
Nov 5, 2024

Conversation

jack-berg
Copy link
Member

I'm starting to think about how to allow for updating SDK configuration. Starting with metrics because traces and logs are a cake walk in comparison. While doing some analysis I realized that MeterSharedState is a silly concept - all of its logic and state can just be held directly on the respective SdkMeter.

This reduces complexity and makes it easier to reason over.

@jack-berg jack-berg requested a review from a team as a code owner November 1, 2024 21:15
Copy link

codecov bot commented Nov 1, 2024

Codecov Report

Attention: Patch coverage is 96.92308% with 4 lines in your changes missing coverage. Please review.

Project coverage is 90.47%. Comparing base (e4f3978) to head (5a341ab).
Report is 3 commits behind head on main.

Files with missing lines Patch % Lines
...in/java/io/opentelemetry/sdk/metrics/SdkMeter.java 95.87% 3 Missing and 1 partial ⚠️
Additional details and impacted files
@@             Coverage Diff              @@
##               main    #6845      +/-   ##
============================================
- Coverage     90.49%   90.47%   -0.02%     
+ Complexity     6599     6588      -11     
============================================
  Files           731      729       -2     
  Lines         19738    19724      -14     
  Branches       1938     1941       +3     
============================================
- Hits          17862    17846      -16     
- Misses         1285     1286       +1     
- Partials        591      592       +1     

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

@jkwatson
Copy link
Contributor

jkwatson commented Nov 2, 2024

I believe this was a holdover from OC metrics, where (IIRC), you could have more than one meter instance that shared the same state. If we don't need it any more, then 🥂 !

@jack-berg jack-berg merged commit 7e4da16 into open-telemetry:main Nov 5, 2024
25 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.

3 participants