Skip to content

Disable automatic propagator for OTLP #5299

Closed

Description

@jamescrosswell

According to the docs:

The integration MUST NOT set up an automatic propagator. Cross-service trace propagation is handled by the propagateTraceparent setting or by user-configured OTel propagators. How to set up an OTel propagator is a documentation concern.

So our current behaviour is inconsistent with the docs.

When using OTLP, presumably users can and should configure the propagators via OTEL (not Sentry):

@ericsampson this is a bit different to what you were expecting... but it's also how all of our other OTLP integrations behave so I don't think we have much wiggle room on this one.

Originally posted by @jamescrosswell in #5217 (comment)

Documentation

Make sure that the docs are consistent when publishing this change:

Activity

  1. linear-code commented on Jun 22, 2026

    @linear-code
  2. added
    Bug
    on Jun 22, 2026
  3. added
    .NET
    on Jun 22, 2026
  4. Flash0ver commented on Jun 24, 2026

    @Flash0ver
    Contributor

    We are thinking to remove the TextMapPropagator argument from

    public static void UseOtlp(this SentryOptions options, TracerProviderBuilder tracerProviderBuilder, Uri? collectorUrl = null, TextMapPropagator? defaultTextMapPropagator = null)

    and instead advice users in docs and samples to set the propagator directly explicitly:

    Sdk.SetDefaultTextMapPropagator(new SentryPropagator());
    Sdk.SetDefaultTextMapPropagator(new CompositeTextMapPropagator([new SentryPropagator(), new MyPropagator()]));
  5. added
    public API
    on Jun 24, 2026
  6. added
    Breaking Change
    on Jul 2, 2026
  7. added
    Next Major
    on Jul 2, 2026
  8. removed
    Bug
    on Jul 16, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    .NETBreaking ChangeNext MajorState: BlockedTracespublic API

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions