Closed jorgebay closed 5 years ago
Are you 100% sure this is not an issue with the system you are running against? I tried it, but could not reproduce.
The response times shown are larger than app latency.
What is app latency here? How are you measuring that?
Are you 100% sure this is not an issue with the system
yes, I've tested with ab at the time, the "real latency" is similar to the one shown on the first chart.
How many users do you run with? Does the problem still occur when running with a single user?
Also, could you maybe try running ab and locust at the same time?
Maybe it is possible (but unlikely) that the exactly predictable sleep time makes all the requests happen on the same millisecond (instead of being spread out evenly), which impacts locusts performance, making it have problems with measuring response times correctly.
Are you ramping up very fast?
Maybe it is possible (but unlikely) that the exactly predictable sleep time makes all the requests happen on the same millisecond
My guess was along these lines...
How many users do you run with? Does the problem still occur when running with a single user?
I've tested with 200 and 300, using 100 spawns per sec. Maybe that's too fast.
100/s is high, although I think I've had it that high with no issues. See if you still get the problem with 10/s.
It was a cloud deployment that I already teared down...
I can give it a try locally to see if I can consistently reproduce. I was using a EC2 m5.large
instance (2 VCPU).
Description of issue
When setting the same value for
min_wait
andmax_wait
(greater than 0), the results show response times that are greater than real latency.Expected behavior
Show real response times, regardless of whether the wait time is constant or random.
Actual behavior
The response times shown are larger than app latency.
Using
min_wait = 500
andmax_wait = 1500
:p50: ~5ms ✅
Using
min_wait = 1000
andmax_wait = 1000
:p50: >20ms ❌
Environment settings
Steps to reproduce (for bug reports)
Sample locustfile.py: