fix(sdk-node): warn and ignore zero exporter timeout in declarative config#6711
Merged
trentm merged 5 commits intoMay 15, 2026
Merged
Conversation
The spec says timeout of 0 means "no limit (infinity)" but the JS exporters don't support that yet (open-telemetry#6617). Add validateExporterTimeout that warns and returns undefined for zero values, causing the exporter to fall back to its default timeout. Closes open-telemetry#6618 Assisted-by: Claude Opus 4.6
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #6711 +/- ##
=======================================
Coverage 94.86% 94.86%
=======================================
Files 376 376
Lines 12712 12717 +5
Branches 2883 2884 +1
=======================================
+ Hits 12059 12064 +5
Misses 653 653
🚀 New features to boost your workflow:
|
Assisted-by: Claude Opus 4.6
trentm
approved these changes
May 14, 2026
github-merge-queue
Bot
removed this pull request from the merge queue due to a conflict with the base branch
May 14, 2026
…rter-timeout # Conflicts: # experimental/CHANGELOG.md # experimental/packages/opentelemetry-sdk-node/src/utils.ts
…bio/opentelemetry-js into mike/warn-zero-exporter-timeout # Conflicts: # experimental/CHANGELOG.md
trentm
added a commit
to trentm/opentelemetry-js
that referenced
this pull request
May 19, 2026
…emetry#6711) but missed in the concurrent open-telemetry#6708 PR
7 tasks
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.
Which problem is this PR solving?
The declarative config schema says a
timeoutof0means "no limit (infinity)" for OTLP exporters. However, the JS exporters don't support infinite timeout yet (#6617). Currently,timeout: 0is passed through silently and may cause unexpected behavior.Short description of the changes
Add
validateExporterTimeout()helper in sdk-node'sutils.tsthat checks for zero timeout values when creating exporters from declarative config. Whentimeout: 0is configured:diag.warnexplaining that infinite timeout is not supportedundefinedso the exporter falls back to its default timeout (10000ms)Applied to all OTLP trace exporter creation paths (HTTP json, HTTP protobuf, gRPC).
Note: the metric and log exporter paths don't currently pass
timeoutthrough — that's being addressed in #6707 and #6708. Once those merge, this validation should be applied there too.Type of change
How Has This Been Tested?
189 sdk-node tests pass. Full lint passes.
Checklist:
Closes #6618