Throughput Controller in JMeter

  • The Throughput Controller allows the user to control how often it is executed. There are two modes:
    • Percent execution: This causes the controller to stop executing after a certain number of executions have occurred.
    • Total executions : This causes the controller to stop executing after a certain number of executions have occurred.
  • Like the Once Only Controller, this setting is reset when a parent Loop Controller restarts.

The Following Example Demonstrates the Throughput Controller :

  • Open the JMeter and then add thread Group into your Test Plan and enter the number of Users as 10.
    add-userd-to-thread-group-jmeter
  • Next, add Three HTTP Request Samplers Inside the Thread Group as shown below. First I am going to add HTTP Request and entering the Homepage Address of the New Tours demo site as shown below.
    throughtput-controller-homepage-request-jmeter
  • Add one more HTTP Request and enter the Welcome page address in the Server name as below.
    mercury-welcome-page-jmeter
  • Add one more HTTP Request and enter the Register page address.
    register-page-jmeter
  • Add Aggregate Report to the Thread Group as below.
    aggregate-report-to-throughtput-jmeter
  • Now save and run the TestPlan, after the execution, all the requests have been hit by the 10 virtual users.
    virtual-users-hit-by-ten-users-jmeter
  • But, my retirement here that, I want to distribute virtual users to each request.
  • So I want 2 users to hit Home Page,3 Users to hit the Welcome page and 5 users to hit the Register page.
  • This can be done by using the Throughput Controller.
  • Add three Throughput controller to the Thread Group and then assign each request to the different throughput controller.
    add-throughput-controller-to-the-each-requests-jmeter
  • Next, click on the Throughput controller and then select the Percentage Execution and then enter the percentage of the throughput as 20%, 30%, and 50% in each throughput.
    throughtput-percentage-jmeter
  • After entering the throughput percentage in each in throughputs, save and execute the Test Plan.
    execution-of-throughtput-jmeter
  • The Throughput will help us to distribute the virtual users based on a percentage if a Test Plan is having multiple numbers of Thread Groups.
Comment / Suggestion Section
Point our Mistakes and Post Your Suggestions