The JMeter Plugin Parallel Controller is very helpful for a number of different testing scenarios.
For example, if you have to log in to a website and then have to fetch data. You may have created one thread group and created two HTTP requests, one for login and one to fetch data. But you want the login HTTP request to hit one time and data fetching to hit for many virtual users. How will this work if there is one common thread group for both?
If you need to run all requests after login in parallel, you can use the JMeter Plugin Parallel Controller plugin:
- Install JMeter Plugin Manager: Download plugins-manager.jar and put it into lib/ext directory, then restart JMeter.
- Open menu Options -> Plugins Manager
- Install Parallel Controller & Sampler plugin.
- Add the Parallel Controller to the Test Plan: Right click on Thread Group -> Add -> Logic Controller -> bzm – Parallel Controller
- Add your request samplers inside Parallel Controller.
Choose your Thread Group and set the number of threads (users) and loop count.
Each thread will execute the test plan in its entirety and completely independently of other test threads. Multiple threads are used to simulate concurrent connections to your server application.
So, if you want to run login sampler just once, set:
- Number of Threads (users) to 1
- Loop Count to 1
There are also different types of Thread Groups. Check the official documentation for more information.