Skip to content

OpenTracing Shim: ScopeManager.Activate can throw if span is not sampled  #4728

Open
@pjanotti

Description

The current implementation of ScopeManager uses a ConditionalWeakTable to associate an Activity to a SpanShim. However, if the Activity used by the shim is not being sampled the associated Activity will be the singleton TelemetrySpan.NoopInstance and the Add method on ConditionalWeakTable will throw an exception. Repro test: 57845b2#diff-64d0dfb854bfa159bf2bfd49d7349af30848d52f4b9147e47e423b1e2d3399adL31

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions