Throughput controller is not working as expected

42 views
Skip to first unread message

Rupali W

unread,
Jun 8, 2024, 6:27:47 AMJun 8
to JMeter Forum
Hi Group,
I need to prepare script where my requirement is - All Users login to app wait 30sec, load dashboard and then some of the users will executed Throughput 1 transactions, some will execute Throughput 2 and some will execute Throughput 3 and then Logout.
I have configured jmeter script with below configuration-

Jmeter.JPG

If i am having 3 Users i expected All users login to application, load dashboard and then divide them into different throughput controller. However it is observed that thread-1 executed 1st throughput and again execute throughput 2 and 3. And even logout happens even before starting the throughput controller. Due to this 401 error occurs.

Jmeter2.JPG
Can anyone plz help me to configure this. I did it previously and it was working expected. I am not sure now, what i am missing at ? 
Appreciate your help and suggestions. Thanks.

DT

unread,
Jun 8, 2024, 11:01:43 AMJun 8
to JMeter Forum
If you need the guarantee of the fact each action needs to be executed at least once consider migrating to Switch Controller or Weighted Switch Controller

With regards to Samplers execution order it looks weird, JMeter should be executing Samplers upside down, do you have more than 1 iteration by any chance? You can use ${__threadNum} and ${__groovy(vars.getIteration(),)} functions as your samplers labels prefix/postfix, this way you will be able to distinguish requests coming from different iterations.

Rupali W

unread,
Jun 9, 2024, 8:06:00 AMJun 9
to JMeter Forum
Hi Dmitri Thank so much for your response.
I am not using loop here. I want to execute all transactions at least once. I tried implementing Weighted switch, however Weighted switch is not working as per my requirement.

My requirement is
All users login and out of all
33 % users doing 1st transaction
33 % users doing 2nd  transaction
34 % users doing 3rd transaction
All users logout from application

However Weighted switch is working as - 
all users login to application
all users perform either 1st or 2nd or 3rd transactions 

Please suggest. thanks.

Rupali W

unread,
Jun 9, 2024, 9:00:34 AMJun 9
to JMeter Forum
Hi Here is the sample script  output for 6 user test. As seen below launch app is executed by all threads however transactions in throughput controller are executed only by 2nd and 5th threads. Jmeter3.JPG
Reply all
Reply to author
Forward
0 new messages