Reputation: 398
machine1:
java -jar selenium-server-standalone-2.43.1.jar -role hub
machine2:
java -jar selenium-server-standalone-2.43.1.jar -role node -browser browserName=chrome,maxInstances=1
All tests go to web app on the third machine. From fourth machine I run same amount of tests:
locally: 0m27s
remotely through grid: 2m50s
All of them running on the same local network. Why it's so slow then? What should I check to find the bottleneck?
UPDATE1: ping between all machines ~0.03ms-0.89ms
Upvotes: 2
Views: 4576
Reputation: 398
So the problem was in abnormal load at the machine1 with grid server proccess running.
# uptime
14:35:31 up 9 days, 21:55, 2 users, load average: 2.86, 2.18, 2.16
I moved selenium grid server process to other fresh machine and everything speeds up.
Upvotes: 0
Reputation: 2402
I'd check the ping times between the servers. (I'm assuming in every case the test are running through the grid.)
If not, the grid is going to be your bottleneck.
You can speed things up if you keep in mind that every time you try to retrieve something from the web page, it has to go through the grid. Many times you can cache information.
I wrote about that here: http://blog.dmbcllc.com/selenium-performance-improvements/
Upvotes: 1