Skip to content

Http.HttpRequestOut OpenTelemetry spans not finished if filtered #3197

@jamescrosswell

Description

@jamescrosswell

Problem

For background context see:

If OpenTelemetry is configured with filtering - e.g. as follows:

AddHttpClientInstrumentation(o => o.FilterHttpRequestMessage = _ => false)

... then our SentrySpanProcessor receives OnStart events for any outgoing requests from HttpClient but never receives a corresponding OnEnd event.

This leaves a bunch of SentrySpan instances accumulating in SpanProcessor._map, which never get cleaned up.

Investigation

Metadata

Metadata

Labels

BugSomething isn't working

Projects

Status

Done

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions