-1

I'm new at using Apache Jmeter , i want to use Apache Jmeter for doing load testing , I've created java code using selenium , i want to integrate my java code into apache jmeter for doing load testing for my application.

I've installed Jmeter , then i'm unable to proceed further even after searching on Google for steps.

public static void main(String arg[]) {
    String ChromDriver = GeneralUtils.readConfig("ChromeDiver");
    ChromeOptions options = new ChromeOptions();
    options.addArguments("start-maximized");
    options.addArguments("disable-infobars");
    WebDriver browser = new ChromeDriver(options);
    Login(browser);
    Perform(browser);
    Logut(browser);
}

Now when run on eclipse , its just for one user. I want to do for bulk users. So is either any to export this project via jar or java then do load testing using Apache Jmeter.

3 Answers3

0

can you try this webdriver plugin/listener for jmeter webdriver jmeter

Ramprasad
  • 328
  • 1
  • 3
  • 7
  • Thanks Ramprasad but it seems totally different scenario.Would you tell about Java and selenium related – Shubham Shah May 08 '19 at 16:02
  • then, sorry, not sure what you are looking for . you may use selenium grid as well if you are looking for multiple test runs – Ramprasad May 10 '19 at 03:25
0

There are various ways to run selenium. If you want selenium jar to be executed by Jmeter then Junit Request sampler can be used.Though, it may require some modification. Check the below link it has many options including Junit.

Running Selenium scripts with JMeter

Hope this helps.

sunny_teo
  • 1,961
  • 1
  • 7
  • 11
0

Found the solution of integrating the Java Code + Selenium Script + Apache Jmeter.

Wrote a small blog on it. Can refer here : https://th3javacode.wordpress.com/2019/05/11/performing-load-test-using-jsajava-selenium-apache-jmeter-and/