Skip to content

Refactor the OpenTelemetry package #1066

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

Merged
merged 6 commits into from
Jun 12, 2024
Merged

Conversation

rowanmanning
Copy link
Member

@rowanmanning rowanmanning commented May 31, 2024

This refactors the package, splitting things into more testable modules ahead of adding in metrics support. I tried adding support already but the tests get unwieldy and it was difficult to reason about anything; I took a step back and did some refactoring which will make adding metrics a lot easier.

I tested this manually as well by linking it into a local project and testing that traces come through in Jaeger.

@rowanmanning rowanmanning added the package: opentelemetry Related to the OpenTelemetry package label May 31, 2024
@rowanmanning rowanmanning requested review from next-team and a team as code owners May 31, 2024 11:48
@rowanmanning rowanmanning force-pushed the opentelemetry-refactor branch from 7cff94c to 39b3c99 Compare June 12, 2024 12:50
@rowanmanning rowanmanning enabled auto-merge (rebase) June 12, 2024 12:51
Copy link
Member

@alexmuller alexmuller left a comment

Choose a reason for hiding this comment

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

Nice, splitting this out into different bits in lib/ makes it more clear.

Question: did you want to update the use of appInfo to the new changes you added in #1082?

Non-blocking but I am slightly confused by the move of options.authorizationHeader to options.tracing.authorizationHeader but then you've kept the same environment variable of OPENTELEMETRY_AUTHORIZATION_HEADER which suggests that we will be sharing it between traces and metrics?

@rowanmanning rowanmanning merged commit ad0245d into main Jun 12, 2024
14 checks passed
@rowanmanning rowanmanning deleted the opentelemetry-refactor branch June 12, 2024 15:44
@rowanmanning
Copy link
Member Author

Question: did you want to update the use of appInfo to the new changes you added in #1082?

Yep I'll do that in a later PR, didn't want to delay this one.

Non-blocking but I am slightly confused by the move of options.authorizationHeader to options.tracing.authorizationHeader but then you've kept the same environment variable of OPENTELEMETRY_AUTHORIZATION_HEADER which suggests that we will be sharing it between traces and metrics?

I couldn't be bothered to try and change the name of that one yet. I may deprecate this environment variable and switch to OPENTELEMETRY_TRACING_AUTHORIZATION_HEADER in future though

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
package: opentelemetry Related to the OpenTelemetry package
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants