-
Notifications
You must be signed in to change notification settings - Fork 651
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
Add schema_url to Resource #1871
Add schema_url to Resource #1871
Conversation
Co-authored-by: Eddy Lin <[email protected]>
Co-authored-by: Eddy Lin <[email protected]>
Co-authored-by: Eddy Lin <[email protected]>
…elemetry-python into add-schema_url-attribute
Improves readability from the last commit
This reverts commit 2801745.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for taking this on, making the schema_url an optional argument would prevent the need to change all the calls to it in the tests. It will also prevent this from being a breaking change for users.
…dd-schema_url-attribute
Adds a test to verify the behavior of aggregating ResourceDetectors with different schema URLs. Verifies that merge error logs contain both conflicting URLs.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice I think this is getting pretty close, please take a look at my comments and update the branch!
#1862
A change in the OTel specification requires a new
schema_url
field in theResource
class. This change implements the field, updates theResource
factory method and merge method, updates the behavior ofOTELResourceDetector
when aggregatingResource
s, and modifies tests which used the old constructor signature.Type of change
How Has This Been Tested?
All
tox
tests were ran on Python 3.9. Three tests were made or substantively modified, with a number of others modified for failing to conform to the new constructor signature.Does This PR Require a Contrib Repo Change?
The OTel specification has changed which prompted this PR to update the method interfaces of
opentelemetry-api/
oropentelemetry-sdk/
Yes.
No.
Checklist: