I am running selenium hub in one machine, let it be hub_machine and I am registering nodes to that hub from machines(m1, m2, m3). I am able to do this part without any problem. Now using the remote web driver I am passing commands from m1, m2, m3 to the hub_machine to invoke the browser on these machines using the below code.
WebDriver selenium = new RemoteWebDriver(new URL("http://localhost:4444/wd/hub"), DesiredCapabilities.chrome());
But when I do this, as three nodes are registered to the hub, hub is creating new session on the first node in the list of available nodes. How do I specify the hub to create a session on particular node?