0
votes

I have a JMeter test plan that contains multiple thread groups with different workloads and throughputs. I want to use a throughput shaping timer but only apply shaping to one thread group. If I have the timer inside the thread group, it seems to still act on the entire test plan.

For example, if I set it to 6 requests per second and run the test for ten minutes, I get 3,600 entries in the view results tree (which is expected). Unfortunately those 3,600 entries include requests from other thread groups. I was hoping to get 3,600 entries just from this thread group, and then x,000 from the other thread groups.

Can the throughput timer be used like this? Note that I'm not seeing any thread limits here, the requests are milliseconds in length and I have more than enough users to cover the 6 requests per second I'm looking for.

1
Edit: There was one thing that may be a factor. While I have two thread groups, only one has a throughput shaping timer in it. The other one is just a random timer. Would this cause the symptoms I'm seeing, do I need to have both running as throughput shaping timers?Slimy43

1 Answers

0
votes

JMeter Timers obey JMeter Scoping Rules so if you put the Constant Throughput Timer under a Thread Group - it will be applied only to this thread group

enter image description here

If you're not able to reach the target throughput the reasons could be in:

  1. There are not enough threads in the Thread Group to conduct the desired throughput. Consider using Concurrency Thread Group and connect it to the Constant Throughput Timer via Feedback function
  2. The application fails to respond fast enough. Inspect your application logs, profiler tools output and check whether the application has enough headroom to operate in terms of CPU, RAM, etc.
  3. JMeter cannot send requests fast enough. Consider applying recommendations from step 2 and following JMeter Best Practices. If single JMeter instance cannot create the necessary load you will need to go for distributed testing