Skip to content

Support for Django middleware instrumentation #3723

@obs-gh-abhishekrao

Description

@obs-gh-abhishekrao

What problem do you want to solve?

It's common to see user-defined middleware in Django - https://docs.djangoproject.com/en/5.2/topics/http/middleware/#writing-your-own-middleware

At present, the django instrumentor does not automatically capture them as spans, leaving large gaps of unaccounted time in the trace for applications that use them:

Image

Describe the solution you'd like

Automated creation of spans for middleware calls in django.

Describe alternatives you've considered

  • Manual creation of spans

  • Decorating middleware functions

Additional Context

No response

Would you like to implement a fix?

None

Tip

React with 👍 to help prioritize this issue. Please use comments to provide useful context, avoiding +1 or me too, to help us triage it. Learn more here.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions