Skip to content

feat(api): add experimental env var propagators#1

Closed
pellared wants to merge 1 commit into
mainfrom
pellared-env-var-propagation
Closed

feat(api): add experimental env var propagators#1
pellared wants to merge 1 commit into
mainfrom
pellared-env-var-propagation

Conversation

@pellared

Copy link
Copy Markdown
Owner

Fixes open-telemetry#3285
Design discussion issue (if applicable) N/A

Changes

This adds experimental support for the environment-variable carrier specification so Rust applications can propagate context across parent/child process boundaries without relying on network transports.

  • Add EnvVarExtractor and EnvVarInjector under opentelemetry::propagation, gated behind otel_unstable
  • Normalize environment variable names according to the latest spec for Get, Set, and Keys, while keeping the carrier format-agnostic and value-opaque
  • Document the new API in the crate docs, README, and changelog, and add examples/env-var-propagation to show parent/child process propagation with TraceContextPropagator
  • Follow the latest operational guidance by treating extraction as startup-time input and using a child-process environment copy instead of mutating the parent process environment

Merge requirement checklist

  • CONTRIBUTING guidelines followed
  • Unit tests added/updated (if applicable)
  • Appropriate CHANGELOG.md files updated for non-trivial, user-facing changes
  • Changes in public API reviewed (if applicable)

Add experimental EnvVarExtractor and EnvVarInjector helpers behind the otel_unstable feature flag, document the new API, and add an env-var-propagation example for parent/child process TraceContext propagation.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@pellared

Copy link
Copy Markdown
Owner Author

Closing in favor of the upstream draft PR at open-telemetry#3574.

@pellared pellared closed this Jun 29, 2026
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.

[Feature]: Support the environment variable propagation spec in Rust

1 participant