Skip to content

response_size_histogram for ASGI instrumention #1782

@imanshafiei540

Description

@imanshafiei540

Describe the solution you'd like
Can we have response_size_histogram inside the opentelemetry-instrumentation-asgi logic?
Currently, we do have access to content-length header from the response inside the OpenTelemetryMiddleware, so it would be beneficial that we can have the ability to record response_size like duration.

Describe alternatives you've considered
Currently, I'm thinking about disable the FastAPI auto instrumentation and implement both response size and duration.

Additional context
The only instrumentator I could find that have the ability to record response_size is opentelemetry-instrumentation-tornado (HTTP_SERVER_RESPONSE_SIZE).

Let me know if that makes sense.
Thanks.

Metadata

Metadata

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions