-
Notifications
You must be signed in to change notification settings - Fork 100
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 WithResourceAttributes
option
#522
Add WithResourceAttributes
option
#522
Conversation
Co-authored-by: Robert Pająk <[email protected]>
Co-authored-by: Robert Pająk <[email protected]>
WithAdditionalResourceAttributes
optionWithResourceAttributes
option
Co-authored-by: Robert Pająk <[email protected]>
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.
Outside of @pellared's suggestions, I think this looks good.
Have you done any testing of how this works alongside the SDK picking up resource attributes from the OTEL_RESOURCE_ATTRIBUTES
environment variable? I believe it should be fine as the two sets of attributes will be merged as part of the resource.NewWithAttributes
call.
Thanks @MikeGoldsmith I added some more test cases |
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.
👍
This PR adds
WithAdditionalResourceAttributes
which allows users to pass additional resource attributes that should be reported by the instrumentation