I am creating a script on a simple web application which includes following: 1)Login 2)Some API call(which requires token from login response)
I successfully created the script and executed for one thread which worked fine. Now I am trying increase the load upto 100 threads wherein i got some errors on few API request which got executed before Login sampler(authorization error). Then I put if controller for all API calls(if login success then request API), in this case login will always run first before any API request($JMeterThread.last_sample_ok==true). My manager has told me not to use if controllers in the script because it will consume some time to execute which in turn will affect the final response time. What is the alternate method to achieve this in term of performance aspect.