Search code examples
automationjmeterperformance-testing

Handle Client side actions through JMeter (NOT through Selenium integration)


The Web Application having a list of features(Client-side actions) and These features are not captured, when I record through Jmeter/Blazemeter (NON-API (NON-HTTP) kinds of Stuff). These actions are handled through Javascript functions and .js file is not displayed in Network Tab.

So, I created the selenium scripts and integrated them with Jmeter. When I run the scripts it opens many browser instances(Headless) and performance stats get impacted.

I have to run this script with 5000 Threads. So Opening up so many browser instances is not an appropriate approach.

How to handle the client-side actions through JMeter?


Solution

  • As per JMeter project main page:

    JMeter is not a browser, it works at protocol level. As far as web-services and remote services are concerned, JMeter looks like a browser (or rather, multiple browsers); however JMeter does not perform all the actions supported by browsers. In particular, JMeter does not execute the Javascript found in HTML pages. Nor does it render the HTML pages as a browser does (it's possible to view the response as HTML etc., but the timings are not included in any samples, and only one sample in one thread is ever displayed at a time).

    So you need to figure out what this "client JavaScript" code is doing and replicate this functionality by: