Using Uniform Random Timer As A Constant/Random Timer

We already learnt about what is about uniform random timer and how to use it in your software load test plan in my earlier posts. As you know, uniform random timer has parameters called constant delay offset and Random delay maximum. So if you will set only constant delay offset and run your software load test then it will behave as constant timer. Let's see with example.

Note : There is already stand alone CONSTANT TIMER in apache Jmeter. This example is only for your knowledge enhancement. Interviewer can ask such questions.

Scenario : I have software load test with 4 requests and i wants to apply constant delay of 3 seconds only on all 4 requests using uniform random timer.

In this case, I will set constant delay offset of 3000 milliseconds in my uniform random timer as shown in bellow image.

Now if you will run software load test using above configuration, It will work as a constant timer and apply 3 seconds fixed delay. Result will looks like bellow.

You can see that all the requests are delayed by nearest 3 seconds. Calculation of next request to start execution will works as -> Start time of sample 2 = start time of sample 1 + Sample time of sample 1 + Fixed delay(3000 ms). So Start time of sample 2 = 06:56:10.598 + 1.147 + 3.000 = 14.745.

This way you can use uniform random timer as constant timer in your software load test plan.

No comments:

Post a Comment