Hi, I am trying to understand better what upstream_rq_time and downstream_rq_time exactly measure. I referred to the documentation but it wasn't clear to me. For ex. consider request: service A -> Envoy A -> Envoy B -> Service B; response: Service B -> Envoy B -> Envoy A -> Service A, what do upstream_rq_time and downstream_rq_time mean here? How is the total RTT calculated?
Envoy A's downstream_rq_time measures the time elapsed from when Envoy A starts handling Service A's request until the entire response has sent to Service A.
Envoy A's upstream_rq_time measures the time elapsed from the point where Service A's entire request has been received by the HTTP router filter until the entire upstream response from Envoy B has been received.
The same is true for Envoy B, except the downstream is Envoy A's request/response and the upstream is Service B.
So Envoy A's downstream_rq_time > Envoy A's upstream_rq_time > Envoy B's downtream_rq_time > Envoy B's upstream_rq_time.
Assuming there are no blocking filters in use (e.g. ext_auth) I expect the times to be reasonably close together.
Thanks for clarifying!
This issue has been automatically marked as stale because it has not had activity in the last 30 days. It will be closed in the next 7 days unless it is tagged "help wanted" or other activity occurs. Thank you for your contributions.
This issue has been automatically closed because it has not had activity in the last 37 days. If this issue is still valid, please ping a maintainer and ask them to label it as "help wanted". Thank you for your contributions.
Most helpful comment
Envoy A's downstream_rq_time measures the time elapsed from when Envoy A starts handling Service A's request until the entire response has sent to Service A.
Envoy A's upstream_rq_time measures the time elapsed from the point where Service A's entire request has been received by the HTTP router filter until the entire upstream response from Envoy B has been received.
The same is true for Envoy B, except the downstream is Envoy A's request/response and the upstream is Service B.
So Envoy A's downstream_rq_time > Envoy A's upstream_rq_time > Envoy B's downtream_rq_time > Envoy B's upstream_rq_time.
Assuming there are no blocking filters in use (e.g. ext_auth) I expect the times to be reasonably close together.