-
Notifications
You must be signed in to change notification settings - Fork 625
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
Custom sampler fix #3026
Merged
Merged
Custom sampler fix #3026
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
jeremydvoss
force-pushed
the
custom-sampler-fix
branch
from
November 5, 2022 00:08
28c6390
to
b4629cc
Compare
jeremydvoss
force-pushed
the
custom-sampler-fix
branch
from
November 7, 2022 19:15
60d832f
to
2eb9e4a
Compare
@lzchen @srikanthccv @aabmass . Tagging everyone who participated in the initial PR. |
This PR needs the "Skip Public API check" tag. |
lzchen
reviewed
Nov 9, 2022
opentelemetry-sdk/src/opentelemetry/sdk/_configuration/__init__.py
Outdated
Show resolved
Hide resolved
lzchen
reviewed
Nov 9, 2022
lzchen
reviewed
Nov 9, 2022
opentelemetry-sdk/src/opentelemetry/sdk/_configuration/__init__.py
Outdated
Show resolved
Hide resolved
lzchen
reviewed
Nov 9, 2022
opentelemetry-sdk/src/opentelemetry/sdk/_configuration/__init__.py
Outdated
Show resolved
Hide resolved
lzchen
reviewed
Nov 9, 2022
lzchen
reviewed
Nov 9, 2022
lzchen
reviewed
Nov 10, 2022
opentelemetry-sdk/src/opentelemetry/sdk/_configuration/__init__.py
Outdated
Show resolved
Hide resolved
…_.py Co-authored-by: Leighton Chen <lechen@microsoft.com>
…_.py Co-authored-by: Leighton Chen <lechen@microsoft.com>
…_.py Co-authored-by: Leighton Chen <lechen@microsoft.com>
lzchen
approved these changes
Nov 11, 2022
lzchen
added
the
Approve Public API check
This label shows that the public symbols added or changed in a PR are strictly necessary
label
Nov 11, 2022
srikanthccv
approved these changes
Nov 14, 2022
opentelemetry-sdk/src/opentelemetry/sdk/_configuration/__init__.py
Outdated
Show resolved
Hide resolved
…_.py Co-authored-by: Srikanth Chekuri <srikanth.chekuri92@gmail.com>
…pentelemetry-python into custom-sampler-fix
…_.py Co-authored-by: Leighton Chen <lechen@microsoft.com>
…_.py Co-authored-by: Leighton Chen <lechen@microsoft.com>
…_.py Co-authored-by: Leighton Chen <lechen@microsoft.com>
…_.py Co-authored-by: Srikanth Chekuri <srikanth.chekuri92@gmail.com>
…pentelemetry-python into custom-sampler-fix
jeremydvoss
force-pushed
the
custom-sampler-fix
branch
from
November 17, 2022 19:59
8cef3df
to
99ef804
Compare
6 tasks
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
Approve Public API check
This label shows that the public symbols added or changed in a PR are strictly necessary
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
While the custom sampler injection code worked for unit testing and manual testing. I have discovered a circular dependency bug that can easily occur when the user's sampler depends on trace or sampler modules. So, I'm moving the custom sampler injection to a higher level (configuration) like most entry points to eliminate that issue.
Fixes #3013
Type of change
Please delete options that are not relevant.
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
NOTE: Since TracerProvider is mocked in configuration tests, we test that a default sampler is used by confirming that None was passed in for the Sampler. A test in test_trace.py then confirms that TracerProvider uses the default sampler when None is passed in.
Does This PR Require a Contrib Repo Change?
Checklist: