Skip to content

Play's instrumentation overwrites manually set operation names #1411

@ivantopo

Description

@ivantopo

Our Play instrumentation adds a bit of instrumentation to set the operation name of a request automatically based on the information we get from Play's router, but turns out that this instrumentation runs after the request handler so if we rename the span while running the hadler, that edit will be overwritten by the default name generator. This is kind of related to #702, although not exactly the same.

The sequence of events is a bit weird, and I notice that during the call to routeWithFallback here some user code is executed, even though the filters are evaluated later. I'm not sure if this might be a consequence of misusing the actions or poor understanding of how all of this works. I'll need to dig deeper to figure it out.

At a minimum, we should ensure that if user code modifies the operation name we shouldn't overwrite it with our own.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions