0

I'm trying to make a part of my thread group to be executed only in a last iteration of a thread. A thread will be stopped at some moment of time (by pressing stop at gui while debugging, or by sending stoptest.sh signal to the headless load stations during the load test itself), so I don't know, how many iterations will be executed to that moment. If I knew the exact number, I'd use an If controller with condition like ${__iterationNum} == 50, but that's not the case.

There is a tearDown thread group for such a thing as far as I know, but I need to access my threads local context for the operation I am executing. So basically the question can be asked as - What's the way to determine a "Stop_thread signal was allready sent, and the current iteration is the last one executed"? If i knew how to get it, I could then implement an If controller.

Hope I explained it clear enough, thanks in advance, guys PS Jmeter 4.0

Ivan B
  • 23
  • 5
  • after stop thread signal, it won't start any new work (it will only wrap up current samplers). So even if you find the way to catch that moment, nothing after that will be executed. – timbre timbre Apr 23 '18 at 17:55
  • Thanks for the info. Btw the task, I wanted to implement, was closing WebDriver instances before stoping. Looks like I'll have to just kill the processes manually. – Ivan B Apr 24 '18 at 07:36
  • my usual strategy is to clean up at the beginning of the run (leftovers from previous run) and not at the end. I.e. make it a setUp thread to kill all existing instances of webdriver if any. – timbre timbre Apr 24 '18 at 13:54

0 Answers0