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

[SDK] MeterProvider should own MeterContext, not share it #2218

Merged

Conversation

marcalff
Copy link
Member

@marcalff marcalff commented Jul 6, 2023

Fixes #2204

Changes

Fixed the MeterProvider constructor to use a unique_ptr<MeterContext>, assuming ownership.

For significant contributions please make sure you have completed the following items:

  • CHANGELOG.md updated for non-trivial changes
  • Unit tests have been added
  • Changes in public API reviewed

@marcalff marcalff requested a review from a team July 6, 2023 08:10
@codecov
Copy link

codecov bot commented Jul 6, 2023

Codecov Report

Merging #2218 (a85ffe8) into main (5466c5b) will decrease coverage by 0.03%.
The diff coverage is 0.00%.

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #2218      +/-   ##
==========================================
- Coverage   87.53%   87.49%   -0.03%     
==========================================
  Files         169      169              
  Lines        4889     4891       +2     
==========================================
  Hits         4279     4279              
- Misses        610      612       +2     
Impacted Files Coverage Δ
sdk/src/metrics/meter_provider.cc 86.12% <0.00%> (-5.06%) ⬇️

Copy link
Member

@esigo esigo left a comment

Choose a reason for hiding this comment

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

LGTM
Thanks :)

@marcalff marcalff merged commit 6ecd201 into open-telemetry:main Jul 6, 2023
@lalitb lalitb mentioned this pull request Jul 10, 2023
@marcalff marcalff deleted the fix_unique_meter_context_2204 branch September 5, 2023 15:09
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.

[SDK] MeterProvider should own MeterContext, not share it.
3 participants