Reputation: 1
I have a test which does following
I am able to do this if I have both requests in one throughput controller. But the same is not working if I have 2 requests in 2 different throughput controllers.
Can someone help on this?
Upvotes: 0
Views: 60
Reputation: 13980
There's no limitation for passing values from request under one controller to request under the other, provided they are in the same thread group. However, depending on your Throughput Controller settings, the first GET request may not run always run at the same time as the second GET request from second throughput controller. In other words, both Throughput controllers are making their decisions independently, and do not always make the same decision on whether to run the sampler under them or not.
To resolve this, you need to either introduce a dependency, so that second GET only runs if first got executed, or have 2nd GET to have a default value in case it's not available from the 1st request.
Here's one way to introduce a dependency, as example (many other ways are possible as well):
Throughput Controller 1
GET 1
If Controller <-- check if GET 1 was executed
Throughput Controller 2 <-- runs only if GET 1 was executed
GET 2
Upvotes: 0