title: TimeOut issue and stale instances of webdriver after test fails
body: <p>I am testing a web application using Webdriver, more or less as decribed below. When the tests pass, everything is fine. However, I noticed the below 2 issues when one of the test fails.</p>
  
  <p>a)If one test fails, then the rest of the tests in the suite will timeout without closing the Webdriver instance. So there will be some stale instances of webdriver remaining on the node machine.</p>
  
  <p>b)When one of the tests fail with timeout issue all the remaining tests in that class(as testng is configured to run classes in parallel) fail with the below exception <strong>org.openqa.selenium.remote.UnreachableBrowserException</strong>
   <strong>Error communicating with the remote browser. It may have died.</strong></p>
  
  <p>How can we fix both these issues, could this be an issue with the Grid? Any suggestions will be great. Below are more details about the grid configuration and the environment details.</p>
  
  <p><strong>Browser and version:-</strong> Chrome and version is 23.0.1271.101</p>
  
  <p><strong>Selenium version:-</strong> 2.28.0</p>
  
  <p><strong>Grid hub and node properties:-</strong></p>
  
  <p><em>Hub start :-</em>
  java -jar /tools/grid/selenium-server-standalone-2.28.0.jar -role hub -maxSession 20 -browserTimeout 240 -remoteControlPollingIntervalInSeconds 180 -sessionMaxIdleTimeInSeconds 240 -newSessionMaxWaitTimeInSeconds 250 -timeout 30</p>
  
  <p><em>Node start:-</em>
  java -jar /tools/grid/selenium-server-standalone-2.28.0.jar -role node -Dwebdriver.chrome.driver=/ChromeDriver/23.0.1240/chromedriver –hub <a href="http://mobygrid.dev.ebay.com:4444/grid/register" rel="nofollow">http://mobygrid.dev.ebay.com:4444/grid/register</a></p>
  
  <p><strong>Testng.xml</strong> which runs class in parallel with 5 threads:-</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="UTF-8"?&gt;
  &lt;!DOCTYPE suite SYSTEM "http://testng.org/testng-1.0.dtd"&gt;
  &lt;!--  &lt;suite name="Single Group Suite"&gt; --&gt;
  &lt;suite name="Single Group Suite" parallel="classes" thread-count="5"&gt;
  &lt;test name="Single Group Test Run" preserve-order="false"&gt;
  &lt;groups&gt;
      &lt;define name="completetests"&gt;
                &lt;include name="ViewItem"/&gt;
                &lt;include name="ViewItem2"/&gt;
                &lt;include name="ViewItem3"/&gt;
              &lt;/define&gt;
                 &lt;run&gt;
  &lt;include name="@GROUP@" /&gt;
  &lt;include name="init" /&gt;
  &lt;exclude name="noRun" /&gt;
  &lt;/run&gt;
  &lt;/groups&gt;
  &lt;classes&gt;
  &lt;class name="com.tabletweb.test.tests.ViewItemPageTests" /&gt; 
                                          &lt;class name="com.tabletweb.test.tests.ViewItemPageTests2" /&gt; 
                                          &lt;class name="com.tabletweb.test.tests.ViewItemPageTests3" /&gt; 
  &lt;/classes&gt;
  &lt;/test&gt;
  &lt;/suite&gt;
  </code></pre>
  
  <p>Thanks!</p>