InterviewBuddy
All interview questions

What is the difference between latency and throughput?

Beginner

Answer

Latency is how long one request takes. Throughput is how many requests a system completes over time. Improving one does not always improve the other.

Explanation

Measure percentiles, not only averages. A system can have high throughput while some users experience very slow requests.

Example

p95 latency: 300 ms; throughput: 1,000 requests/s