You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[probes.http] Support full HTTP response latency measurements #1568
I'm evaluating Cloudprober for monitoring the availability and latency of multiple third-party APIs. These are non-streaming HTTP requests that can take up to a minute to complete.
We would like to monitor both the network latency breakdown (DNS, TCP, TLS, etc.) and the end-to-end latency as experienced by the client, including the time required to receive the complete response body.
Current limitation
Currently, the HTTP probe measures latency immediately after client.Do(req) returns, before reading the response body.
As a result, although Cloudprober reads the entire response body, the reported latency does not include the body transfer time. This can underestimate the actual latency experienced by the client, particularly when the server sends response headers early.
Proposed solution
Add two optional measurements to the existing latency_breakdown configuration:
RESPONSE_READ_LATENCY: Time spent reading the response body after receiving the response headers.
TOTAL_LATENCY: Time from initiating the HTTP request to completing the response body read.
The existing latency metric should retain its current semantics for backward compatibility. Both new metrics should support the existing histogram aggregation and latency configuration.
I've opened #1567 with a proposed implementation. Happy to adjust the approach based on maintainer feedback.
Activity