0
votes

I am load testing a scenario in JMeter. I'm trying to achieve a certain amount of r/s and then sustain that for x amount of time. However, with the testing tool, it looks like falling short of r/s for each endpoint. Do I just need more virtual users from the system? or is an additional fix needed for the test plan below?

  HTTP Header Manager 
  User Defined Variables
  DNS Cache Manager
  HTTP Authorization Manager
  HTTP Cache Manager
  Thread Group
     HTTP Cookie Manager
     CSV Data Set Config # 1 
     HTTP Request #1
        HTTP Header Manager
     HTTP Request #2
        HTTP Header Manager
        JSON Extractor
     HTTP Request #3
        HTTP Header Manager
     CSV Data Set Config # 2
     HTTP Request #4
        JSR2223 PreProcessor
        HTTP Header Manager

The CSV Data Set Config # 1 is CSV of username and passwords that are passed to HTTP Requests #1 and #2. The JSON Extractor extracts values from HTTP Request #2 to the HTTP Header Manager of HTTP Request #3.

1
hi . Could You please extend here > I'm trying to achieve a certain amount of r/s and then sustain that for x amount of time. a bit? "amount of r/s" - what do You mean? And also -could You please attach .jmx scenario in the question? I may take a lookeugene.polschikov
Your attached test plan tree does not provide much information about your problem. Please be in more details - i.e How many virtual threads have you used, how many endpoints, requests/samplers had in your test plan, duration of your test, warm up time, warm down time of threads, hold load time (sustain the load for x amount of times?)Masud Jahan
It’s 4 HTTP Requests each with one endpoint (POST, POST, GET, POST). The first CSV is 2000+ username and passwords to pass to the first two HTTP requests (recycle at EOF). The second HTTP request has an access token in response I pass to the subsequent two HTTP Requests. The second CSV is a bunch of attributes passed in the body of last POST HTTP Request. I’ve used BlazeMeter and was able to run 30, 40, 50, and 500 VU for 20-30 minutes. With 500 VU I can hit average throughput of ~80 h/s but that’s total amongst all of the requests. I need to try to hit that for each of the HTTP Requests.TheAutomator

1 Answers

0
votes

I can think of 2 situations:

  1. JMeter isn't capable of sending requests fast enough. If this is the case:

    • Make sure to follow JMeter Best Practices
    • Try increasing the number of threads/ virtual users
    • If you cannot conduct the required load from a single load generator - consider switching to Distributed Testing
  2. Your application under test isn't capable of responding fast enough. The reasons could be:

    • Your application lacks resources (CPU, RAM, Network, Disk, Swap, etc.). Consider monitoring its baseline health metrics using i.e. JMeter PerfMon Plugin
    • Your application middleware configuration isn't suitable for high loads. Inspect configuration of load balancer, application server, database, whatever to see if they're set up good enough for the anticipated load. Check out Web Performance Optimization tips to get initial idea. Normally the vendors of application servers, databases, etc. provide scaling instructions.
    • Your application code is not efficient enough, i.e. uses bad algorithms. You can use profiling tools to check what are the slowest and/or frequently called functions, largest objects, etc.