0

in jmeter script, is it possible to skip the remaining transactions and go to next iteration based on a captured value?

eg:

Thread Group1: Sampler 1 Sampler 2 Sampler 3

whenever the value captured in Transaction 2 is 0, it should skip Transaction 3 and go to next iteration.

pepsin s
  • 29
  • 4

2 Answers2

0

Right click Transaction 3 choose Insert Parent and add If Controller with condition checking that value isn't 0:

 ${jexl3("${value}" != "0")}

If you have saved value from transaction 2, just add Post Processor og Regular expression or JSON extractor depending on your response.

Ori Marko
  • 56,308
  • 23
  • 131
  • 233
0

You can do it using the following function. I have also provided the link to the previous answer from VINS.

ctx.setRestartNextLoop(true);

jmeter stop current iteration

Selva
  • 541
  • 5
  • 16