'How to set limit for particular no. of sample in jmeter
example ,i want JMeter to run for 100 samples only on 100 thread.
Solution 1:[1]
Each JMeter thread (virtual user) executes Samplers upside down for the defined number of iterations.
- If you have 1 Sampler, 100 users and 1 iteration - you will have 100 executions
- If you have 1 Sampler, 100 users and 2 iterations - you will have 200 executions
- If you have 1 Sampler, 200 users and 2 iterations - you will have 400 executions
- If you have 2 Samplers, 200 users and 2 iterations - you will have 800 executions
- etc
The number of users and iterations can be set in the Thread Group.
- If you want to execute a particular sampler only by the 1st user - go for If Controller and use __threadNum() function to determine the number of the current user
- If you want to execute a particular sampler i.e. 5 times and others 100 times - go for Throughput Controller
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
Solution | Source |
---|---|
Solution 1 | Dmitri T |