How to make JMeter user not to wait for response

Advertisements

I’ve got a simple script :
1 thread group – loop 10, user 1
I want a user to send a request per second, so I’ve added **constant throughput timer ** set to 60.0

But my problem is that each request takes around 5 second to get response, that means that even with the timer,test looks like following :
send request -> wait for response 5 seconds -> send another request -> wait again

So loop 10 will take around 50 seconds to finish. but I want :
send request -> don’t wait for response, after 1 second send again -> send again after 1 second -> send again after 1 second

I tried using constant throughput timer, but it doesn’t help. don’t have any other idea. one solution is to set timeout for the requests, but in this case connection will be closed, won’t be it?

>Solution :

JMeter thread (and results analysis) model assumes waiting for the response before starting the next request so there is no way to do this.

The options are in:

  1. If you want to send 1 request per second for 10 seconds you could consider using Throughput Shaping Timer and Concurrency Thread Group combination, if you connect them via Feedback Function JMeter will start extra threads in order to reach and maintain the desired throughput
  2. You can send a HTTP request from JSR223 Sampler using Groovy language via Future Tasks but in that case you will need to develop your own logic of processing and storing the result
  3. It’s possible to extend JMeter by creating your own JMeter Plugin (basically point 2 but more friendly for the end-user and has better performance), you can take a look at how async responses are being handled in the HTTP2 Plugin for JMeter source code

Leave a ReplyCancel reply