0
votes

I configured Java based Selenium WebDriver test in Apache JMeter with the following setup:

  • Number of Threads (Users): 10
  • Ramp-up period (Second): 120
  • Loop Count: 1

I ticked the Delay Thread Creation until needed to save resources.

My expectation regarding the functionality:

I expected that if I have 10 users with 120 seconds ramp up time, then every user activity will start each other and the Jmeter will wait at least 12 seconds to start the next thread.

The issue is: The threads start sometimes within 11 seconds, sometimes 12 seconds. I don't know why does it happen because I would like to see the threads start after each other exactly in 12 seconds.

The question is

Are there any solution that to tell the JMeter to wait exactly 12 seconds for next thread start?

Here is the picture about started jobs with date time stamp:

enter image description here

2

2 Answers

1
votes

I don't think you will be able to achieve this level of precision using ramp-up period approach of the normal Thread Group, a better idea would be going for the Ultimate Thread Group (can be installed using JMeter Plugins Manager) which allows absolute flexibility in terms of definition of ramp-up, ramp-down and time to hold the load.

Example setup:

enter image description here

Example output:

enter image description here

In order to get only one execution of the "job" per each virtual user you can use Throughput Controller configured like:

enter image description here

1
votes

You can add Flow Control Action for pausing exact time

it allows pauses to be included without needing to generate a sample. For variable delays, set the pause time to zero, and add a Timer as a child.