I have a loop controller with an If controller inside of it. The if controller triggers on certain loop iterations to update a Jmeter variable (SystemId). The If controller and groovy script seem to work correctly, however, outside of the if controller the Jmeter variable (SystemId) seems to reset to the value before the If controller executed?
I have put debug samplers/post processors to check the state of the Jmeter variables inside and outside the if controller. The debug inside the loop shows the SystemId variable updated the very next element is the outside sampler which shows the SystemId reverted to the previous value.
Samplers
I have tried various java, groovy, and beanshell approaches to changing the variable. All work with the sampler inside the if controller showing the variable changed, but all still result in the variable value being reverted outside of the if controller as shown by the sampler outside the if controller.
MattSmithBurgess is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.