This would be useful for egress bandwidth accounting. See e.g. https://opentelemetry.io/docs/specs/semconv/registry/attributes/http/#http-request-body-size
The easy version of this would be to just report body sizes based off of content-length headers, which would work for "most" requests. The harder but more complete version would be to use custom Body wrapper(s) to record the actual bytes written, which would additionally work for streaming/chunked-encoding bodies that have no content-length.
This would be useful for egress bandwidth accounting. See e.g. https://opentelemetry.io/docs/specs/semconv/registry/attributes/http/#http-request-body-size
The easy version of this would be to just report body sizes based off of
content-lengthheaders, which would work for "most" requests. The harder but more complete version would be to use customBodywrapper(s) to record the actual bytes written, which would additionally work for streaming/chunked-encoding bodies that have no content-length.