I would like to accomplish the following workflow using JMeter
Is something like this possible in JMeter? If so, does anyone have an example?
This tutorial should fully answer your need:
The most straightforward way to go is using JMeter Assertions.
The most powerful of them is Beanshell Assertion.
In regards to your use cases following code sample may help:
if new String(data).contains("someVar=SUCCESS")
Failure = false;
else
Failure = true;
Similarly for FAIL
For retrying you can use While Controller using some variable as condition like continue which is set to true. Retry as many times as required, when you're fine - just set continue variable to false.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With