Issue 3810 in selenium: Grid 2 and browserName issues

21 views
Skip to first unread message

sele...@googlecode.com

unread,
Apr 26, 2012, 9:16:16 AM4/26/12
to selenium-develope...@googlegroups.com
Status: New
Owner: ----
Labels: Type-Defect Priority-Medium

New issue 3810 by haroo...@gmail.com: Grid 2 and browserName issues
http://code.google.com/p/selenium/issues/detail?id=3810

Steps to reproduce?
I am setting up Grid2 to replace our existing Selenium Grid 1.0.8 set up as
we have started writing WebDriver tests for the new projects, but as part
of that I need to make sure that it works for our existing Selenium RC
tests. In our current implementation we rely on the grid_configuration yml
file and Selenium HUB is responsible to assign machines based on the
configuration in the yml file. e.g.iexplore8-on-windows is mapped to
*iexplore and whenever a test requests for iexplore8-on-windows the HUB
will allocate a session from available RCs.

I am trying to emulate the same behaviour using Grid2.

I have run the Selenium HUB using the following command.
java -jar selenium-server-standalone-2.21.0.jar -role hub

I have registered 2 nodes using the following commands.

java -jar selenium-server-standalone-2.21.0.jar -role node -hub
http://HUB:4444/grid/register -browser
browserName=firefox3-on-windows,seleniumProtocol=Selenium


java -jar selenium-server-standalone-2.21.0.jar -role node -hub
http://HUB:4444/grid/register -browser
browserName=iexplore8-on-windows,seleniumProtocol=Selenium


These 2 nodes are successfully registered and I can see them on the
Selenium HUB Console with the correct browser name.

Our tests then make a request to get the Selenium Session with the
following statement.

startSeleniumSession(serverHost, serverPort, browser, appUrl);

Where browser is the browserName in this case.

But I get the following exception.
java.lang.RuntimeException: Could not start Selenium session:
org.openqa.grid.common.exception.GridException: Error forwarding the new
session The server returned an error : Failed to start new browser session:
Browser not supported: iexplore8-on-windows(Did you forget to add a
*?)Supported browsers include: *firefox *mock *firefoxproxy *pifirefox
*chrome *iexploreproxy *iexplore *firefox3 *safariproxy *googlechrome
*konqueror *firefox2 *safari *piiexplore *firefoxchrome *opera
*webdriver *iehta *custom
at com.thoughtworks.selenium.DefaultSelenium.start(DefaultSelenium.java:89)
at
com.thoughtworks.selenium.grid.tools.ThreadSafeSeleniumSessionStorage.startSeleniumSession(Unknown
Source)
at java.lang.reflect.Method.invoke(Method.java:597)
at com.intellij.rt.execution.application.AppMain.main(AppMain.java:120)
Caused by: com.thoughtworks.selenium.SeleniumException:
org.openqa.grid.common.exception.GridException: Error forwarding the new
session The server returned an error : Failed to start new browser session:
Browser not supported: iexplore8-on-windows(Did you forget to add a
*?)Supported browsers include: *firefox *mock *firefoxproxy *pifirefox
*chrome *iexploreproxy *iexplore *firefox3 *safariproxy *googlechrome
*konqueror *firefox2 *safari *piiexplore *firefoxchrome *opera
*webdriver *iehta *custom
at
com.thoughtworks.selenium.HttpCommandProcessor.throwAssertionFailureExceptionOrError(HttpCommandProcessor.java:97)
at
com.thoughtworks.selenium.HttpCommandProcessor.getCommandResponseAsString(HttpCommandProcessor.java:168)
at
com.thoughtworks.selenium.HttpCommandProcessor.executeCommandOnServlet(HttpCommandProcessor.java:104)
at
com.thoughtworks.selenium.HttpCommandProcessor.doCommand(HttpCommandProcessor.java:86)
at
com.thoughtworks.selenium.HttpCommandProcessor.getString(HttpCommandProcessor.java:262)
at
com.thoughtworks.selenium.HttpCommandProcessor.start(HttpCommandProcessor.java:223)
at com.thoughtworks.selenium.DefaultSelenium.start(DefaultSelenium.java:81)
... 34 more




Selenium version: 2.21.0
OS: Windows
Browser: IE and Firefox
Browser version: IE 8, Firefox 3

I have seen someone mentioning about using the old grid_configuration yml
file for this kind of mapping, but this is also not working for me.

Please feel free to contact me in case of any questions.

Cheers,
Haroon

sele...@googlecode.com

unread,
May 1, 2012, 11:02:12 AM5/1/12
to selenium-develope...@googlegroups.com

Comment #1 on issue 3810 by haroo...@gmail.com: Grid 2 and browserName
issues
http://code.google.com/p/selenium/issues/detail?id=3810

Further more, I found the correct command to launch hub with the grid1 yaml
file. I did the following.

java -jar selenium-server-standalone-2.21.0.jar -role hub –grid1Yml
grid_configuration.yml

and on the node, I found another parameter -environment, so my new command
to register the node to the hub is as follows.

java -jar selenium-server-standalone-2.21.0.jar -role node -hub
http://hub:4444/grid/register -browser
browserName=firefox3-on-windows,seleniumProtocol=Selenium
-environment=firefox3-on-windows

I can see the configuration for this node on the Selenium Beta Console as
follows.

port:5555
host:10.116.130.55
servlets:[]
cleanUpCycle:5000
browserTimeout:0
hubHost:hub
registerCycle:5000
hub:http://hub:4444/grid/register
newSessionWaitTimeout:-1
capabilityMatcher:org.openqa.grid.internal.utils.DefaultCapabilityMatcher
url:http://10.116.130.55:5555
remoteHost:http://10.116.130.55:5555
prioritizer:null
register:true
throwOnCapabilityNotPresent:true
nodePolling:5000
proxy:org.openqa.grid.selenium.proxy.DefaultRemoteProxy
browser:browserName=firefox3-on-windows,seleniumProtocol=Selenium
maxSession:5
role:node
environment=firefox3-on-windows:
hubPort:4444
timeout:300000


but when I try to run the tests , I get the same error as mentioned in the
original defect report, as firefox3-on-windows is not supported.

and interestingly when I try to run the test with *firefox, the test again
throws an error with null pointer exception and complaints about
browserName *firefox is not recognised.

Feel free to contact me in case of any question.

sele...@googlecode.com

unread,
May 3, 2012, 11:09:59 AM5/3/12
to selenium-develope...@googlegroups.com
Updates:
Labels: Component-Grid

Comment #2 on issue 3810 by barancev: Grid 2 and browserName issues
http://code.google.com/p/selenium/issues/detail?id=3810

(No comment was entered for this change.)

sele...@googlecode.com

unread,
May 4, 2012, 7:08:27 PM5/4/12
to selenium-develope...@googlegroups.com

Comment #3 on issue 3810 by eduardom...@gmail.com: Grid 2 and browserName
issues
http://code.google.com/p/selenium/issues/detail?id=3810

I have the same issue in my HUB and it just ignore the -environment
variable. I have 2 environments QA and STG and for each one I have 2 RCs
with same configurations like:

ENV | OS | BROWSER TYPE | BROWSER VERSION
QA WINXP FF 10
QA WIN7 IE 9
STG WINXP FF 10
STG WIN7 IE 9

How Can I set in my testCase the ENV to execute the testcase against?

my env:
Selenium version 2.21.0
HUB and RC started up by ant command in different machines

Thx in advance

Eduardo


sele...@googlecode.com

unread,
Jun 12, 2012, 5:27:54 AM6/12/12
to selenium-develope...@googlegroups.com

Comment #4 on issue 3810 by GARGPULK...@gmail.com: Grid 2 and browserName
issues
http://code.google.com/p/selenium/issues/detail?id=3810

Any update on this ? We are also experiencing the similar issue.


sele...@googlecode.com

unread,
Oct 8, 2012, 5:30:08 PM10/8/12
to selenium-develope...@googlegroups.com

Comment #5 on issue 3810 by alonec...@gmail.com: Grid 2 and browserName
issues
http://code.google.com/p/selenium/issues/detail?id=3810

Exactly the same problem with 2.25 :(
Any work arounds on -environment variable?

sele...@googlecode.com

unread,
Nov 28, 2012, 6:17:12 AM11/28/12
to selenium-develope...@googlegroups.com

Comment #6 on issue 3810 by mmks...@gmail.com: Grid 2 and browserName issues
http://code.google.com/p/selenium/issues/detail?id=3810

(No comment was entered for this change.)

Attachments:
Error.txt 0 bytes

sele...@googlecode.com

unread,
May 8, 2013, 1:48:03 PM5/8/13
to selenium-develope...@googlegroups.com
Updates:
Status: NeedsClarification

Comment #7 on issue 3810 by barancev: Grid 2 and browserName issues
http://code.google.com/p/selenium/issues/detail?id=3810

Is this issue still actual? Please provide detailed info about hub and node
start option and the content of yml file.

--
You received this message because this project is configured to send all
issue notifications to this address.
You may adjust your notification preferences at:
https://code.google.com/hosting/settings

sele...@googlecode.com

unread,
Aug 15, 2013, 12:40:43 PM8/15/13
to selenium-develope...@googlegroups.com
Updates:
Status: Invalid

Comment #8 on issue 3810 by barancev: Grid 2 and browserName issues
http://code.google.com/p/selenium/issues/detail?id=3810

Closing due to inactivity. Please ask to reopen if the issue is still
actual.

sele...@googlecode.com

unread,
Sep 4, 2014, 7:58:49 AM9/4/14
to selenium-develope...@googlegroups.com

Comment #9 on issue 3810 by vinoth2...@gmail.com: Grid 2 and browserName
issues
https://code.google.com/p/selenium/issues/detail?id=3810

I am also getting the same error which mentioned in the original issue even
i start selenium server in different port (say: 5555).

Issue which i faced :
Hub: Port 5555
Node1: Port 5566
Node2: Port 5556

Running the script parallel on two different machines. Session is getting
created for one machine and the same is not created for another.

Error which i get while running in two different nodes:

FAILED: execution("Input_1", "Object")
java.net.BindException: Selenium is already running on port 4444. Or some
other service is.
at org.openqa.selenium.server.SeleniumServer.start(SeleniumServer.java:491)
at guiauto.BaseAuto.execution(BaseAuto.java:70)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at
org.testng.internal.MethodInvocationHelper.invokeMethod(MethodInvocationHelper.java:84)
at org.testng.internal.Invoker.invokeMethod(Invoker.java:714)
at org.testng.internal.Invoker.invokeTestMethod(Invoker.java:901)
at org.testng.internal.Invoker.invokeTestMethods(Invoker.java:1231)
at
org.testng.internal.TestMethodWorker.invokeTestMethods(TestMethodWorker.java:127)
at org.testng.internal.TestMethodWorker.run(TestMethodWorker.java:111)
at org.testng.TestRunner.privateRun(TestRunner.java:767)
at org.testng.TestRunner.run(TestRunner.java:617)
at org.testng.SuiteRunner.runTest(SuiteRunner.java:334)
at org.testng.SuiteRunner.access$000(SuiteRunner.java:37)
at org.testng.SuiteRunner$SuiteWorker.run(SuiteRunner.java:368)
at org.testng.internal.thread.ThreadUtil$2.call(ThreadUtil.java:64)
at java.util.concurrent.FutureTask.run(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
Reply all
Reply to author
Forward
0 new messages