Selenium Grid2 - Is it possible to run 10 Chrome instances?
Asked Answered
C

1

6

Currently Selenium Grid2 running with the default config shows that it can run 5 firefox browsers, 5 chrome browsers and 1 IE. With a max of 5 instances at the same time.

How can I change this so that it runs 10 chrome instances at the same time?

I have succesfully changed the maxsession parameter of the node with -maxSession 10. However when I run 10 tests, the hub shows that 5 are in queue waiting to be executed.

I dont know if this matters or not, but the hub itself shows a maxSession params of 5. Yet this one I couldn't change.

Any ideas on how to do this?

Cinchonism answered 29/11, 2011 at 15:24 Comment(0)
C
7

I figured it out:

run the node with the argument of MaxSession, and let the browser Configuration have the MaxInstances parameter, ie:

java -jar $JARFILE -Dwebdriver.chrome.driver=$CHROMEDRIVER -role webdriver -hub http://$HUB_IP:4444/grid/register -maxSession 10 -browser browserName=chrome,maxInstances=10"

pretty straightforward actually...

Cinchonism answered 30/11, 2011 at 18:21 Comment(4)
I don't think it's a good idea to run 10 Chrome instance in one machine. Do you think about employ VM? Because if some of the case fail, it's had to figure out the real problem.Carrington
Yeah you are right, its very likely for them to fail given so many instances. I was mostly trying to figure out HOW to do it so I can tune it along the way. Good observation though.Cinchonism
I find the Grid system a bit unstable to use. :( RemoteWebDriver running individually without using RemoteWebDriver finds elements fine, but then using RemoteWebDriver I get annoying errors in my log saying GET and XPATH not recognised.Offshore
Hmm, those particular errors I havent encountered. I have found that grid is more unstable, and ocassionally the communication between the node and the hub will be lost, and the driver cant control the instance. Thats when I usually get all those errors that he cant "find" anything. But when the hub and node are connected, it runs smooth, just like a local webdriver.Cinchonism

© 2022 - 2024 — McMap. All rights reserved.