Valgore
Valgore

Reputation: 53

JMeter: Stop Thread Group after first HTTP request fails

I am testing a mobile app, and I have a Thread Group with about 40 HTTP requests, with the first being an access token request. What I want to do is if the access token fails, skip that current thread iteration.

Upvotes: 4

Views: 2190

Answers (1)

Dmitri T
Dmitri T

Reputation: 168052

There are at least 3 options:

  1. You can define what action to take on sampler error on Thread Group level

Thread group

  1. If you need to limit this behavior to one sample add a Result Status Action Handler as a child of the request
  2. If you need to skip current iteration based on certain condition use Test Action sampler in combination with If Controller

Upvotes: 4

Related Questions