2 Minutes To Code (β Version)

JMeter - 2 minute tutorial

Example of Uniform Random Timer (sample usage)

A Uniform Random Timer will delay consecutive requests of the same thread by a random interval within lower and upper bounds. Let's see an example of Uniform Random Timer in use.

The thread group used has no. of threads set to 5, loop count of 1, and 2 HTTP sampler called 'Home Request' & Changes Request are used. We will add a Uniform Random Timer to our Test Plan (Image 1). This timer has a fixed component called Constant Delay Offset (eg. 1000 ms)and a variable component that will vary between 0 ms and the value of field Random Delay Maximum for eg. 200 ms(Image 2).

Image 3 shows the result when synchronizing timer is not used. Notice that the Changes Request sampler of all threads fire as soon as their respective Home Request sampler completes.

Image 4 shows the result when Uniform Random Timer is used. Notice that the Changes Request sampler of all threads is delayed between 1000 ms and 1200 ms from the end of Home Request.



Image 1: Adding Uniform Random Timer

Image 2: Configuring Uniform Random Timer

Image 3: Result without Uniform Random Timer

Image 4: Result with Uniform Random Timer