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

feat(sdk-trace-base): add spanProcessors property in TracerConfig interface #5138

Merged

Conversation

david-luna
Copy link
Contributor

@david-luna david-luna commented Nov 12, 2024

Which problem is this PR solving?

addSpanProcessor API is planned to be removed in the next major version. This PR adds the spanProcessors config option in the tracer provider base class so users can migrate to this new way of configuring the tracer provider.

Ref #4792

Short description of the changes

  • added spanProcessors property in TracerConfig
  • update BasicTraceProvidet.test.ts to test the new property
  • update @opentelemetry/sdk-node to use the new constructor API
  • remove TracerProviderWithEnvExporter class from @opentelemetry/sdk-node
  • update @opentelemetry/sdk-node tests

Type of change

Please delete options that are not relevant.

  • New feature (non-breaking change which adds functionality)

How Has This Been Tested?

  • compiled all packages
  • ran unit tests

Checklist:

  • Followed the style guidelines of this project
  • Unit tests have been added
  • Documentation has been updated

Copy link

codecov bot commented Nov 12, 2024

Codecov Report

Attention: Patch coverage is 91.25000% with 7 lines in your changes missing coverage. Please review.

Project coverage is 93.17%. Comparing base (f1ef596) to head (4b41b62).
Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
...ental/packages/opentelemetry-sdk-node/src/utils.ts 88.70% 7 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #5138      +/-   ##
==========================================
- Coverage   93.21%   93.17%   -0.05%     
==========================================
  Files         315      314       -1     
  Lines        8096     8076      -20     
  Branches     1622     1622              
==========================================
- Hits         7547     7525      -22     
- Misses        549      551       +2     
Files with missing lines Coverage Δ
...imental/packages/opentelemetry-sdk-node/src/sdk.ts 97.38% <100.00%> (+1.84%) ⬆️
...elemetry-sdk-trace-base/src/BasicTracerProvider.ts 95.68% <100.00%> (+0.11%) ⬆️
...ental/packages/opentelemetry-sdk-node/src/utils.ts 87.95% <88.70%> (+2.23%) ⬆️

@david-luna david-luna marked this pull request as ready for review November 12, 2024 11:38
@david-luna david-luna requested a review from a team as a code owner November 12, 2024 11:38
Copy link
Member

@pichlermarc pichlermarc left a comment

Choose a reason for hiding this comment

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

just two nits, looks good overall (most of this has been reviewed at #5134 - so I mostly skimmed over it) 🙂
thanks for working on this 🙌

CHANGELOG.md Outdated Show resolved Hide resolved
@david-luna david-luna changed the title refactor(sdk-trace-base): add spanProcessors property in TracerConfig interface feat(sdk-trace-base): add spanProcessors property in TracerConfig interface Nov 12, 2024
@david-luna david-luna added this pull request to the merge queue Nov 12, 2024
Merged via the queue into open-telemetry:main with commit db14633 Nov 12, 2024
21 checks passed
@david-luna david-luna deleted the 4792-deprecate-add-span-processor branch November 12, 2024 15:54
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.

2 participants