Ramesh Raja wrote:
Hi Team,

We're trying to use Jmeter and Selenium for performance testing. When we
run scripts with one thread, the execution succeeds; however, if we run the
scripts with five threads, two or three of the threads fail every time

We tried with reducing the ramp-up time and made use of the Selenium Grid
feature.yet having the same problem.
--
Thanks & Regards,

*Ramesh Raja*

rajaramesh2...@gmail.com

Unfortunately your "fail" statement doesn't tell the full story, you need to share at least response message and jmeter.log file <https://jmeter.apache.org/usermanual/get-started.html#logging>contents so we could understand what's going on. Also it's not very clear how do you integrate JMeter with Selenium. If you use some custom Groovy code in JSR223 Samplers- make sure that it's thread-safe <https://www.baeldung.com/java-thread-safety> and you're not re-using the same WebDriver instance by multiple threads.

Also be aware of WebDriver Sampler <https://jmeter-plugins.org/wiki/WebDriverSampler/> plugin which provides JMeter integration with Selenium and it's suitable for multi-threaded execution.

And last but not the least, using real browsers for load testing is not recommended by either Selenium developers <https://www.selenium.dev/documentation/test_practices/discouraged/performance_testing/> or WebDriver Sampler developers <https://jmeter-plugins.org/wiki/WebDriverTutorial/>, you should be using HTTP Request <https://jmeter.apache.org/usermanual/component_reference.html#HTTP_Request> samplers to create the main load (make sure to configure JMeter to behave like a real browser <https://guide.blazemeter.com/hc/en-us/articles/206733719-How-to-make-JMeter-behave-more-like-a-real-browser>) and i.e. 1 instance of WebDriver for checking the frontend performance.

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscr...@jmeter.apache.org
For additional commands, e-mail: user-h...@jmeter.apache.org

Reply via email to