fix(sdk-node)!: fail-fast on TracerProvider creation from config file - #6962
Draft
trentm wants to merge 17 commits into
Draft
fix(sdk-node)!: fail-fast on TracerProvider creation from config file#6962trentm wants to merge 17 commits into
trentm wants to merge 17 commits into
Conversation
This refactors the MeterProvider creation from declarative config in the `startNodeSDK()` code path: - fail-fast (and fallback to a no-op SDK) if the config has unknown values or values that aren't yet supported by the SDK - fixes a number of missed cases - adds a number of TODO for meter_provider config cases to follow-up on (Some of these are to keep this PR smaller, some are because sdk-metrics doesn't yet support everything the declarative config schema supports configuring.) Refs: open-telemetry#6785 Refs: open-telemetry#6107 (comment)
Also limit reading of TLS files to *absolute paths* as required by the declarative config. Note: that doesn't work properly for the 'build-config-from-env-vars' code path. Update to have real TLS files with the usual maint:... npm script. Real TLS files are required by createSslCredentials(), which was being masked before by the just-warn semantics.
…h handles negative, and fails-fast
…d unused utils.ts code and tests
Pull request dashboard statusWaiting on the author · refreshed 2026-07-30 17:31 UTC Move out of draft to request review. Status above doesn't look right?
|
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #6962 +/- ##
==========================================
- Coverage 95.07% 94.99% -0.08%
==========================================
Files 409 409
Lines 14256 14296 +40
Branches 3267 3274 +7
==========================================
+ Hits 13554 13581 +27
- Misses 702 715 +13
🚀 New features to boost your workflow:
|
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
STOP: This PR builds on the feature branch for #6954. That should get merged and this PR updated before reviewing or merging this one. Here is the diff against that feature branch: trentm/opentelemetry-js@trentm-sdk-create-from-config-4...trentm:opentelemetry-js:trentm-sdk-create-from-config-TracerProvider
This refactors the TracerProvider creation from declarative config in the
startNodeSDK()code path:values or values that aren't yet supported by the SDK
Refs: #6785
Refs: #6107 (comment)