且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

超时和浏览器超时之间的区别

更新时间:2023-11-27 21:22:10

文档应为您提供帮助

引用文档


  • 超时 30(默认为300)集线器自动释放未收到任何更多请求的节点之前的超时(以秒为单位)超过指定的秒数。在这段时间之后,该节点将被释放以进行队列中的另一项测试。这有助于清除客户端崩溃,而无需人工干预。要完全删除超时,请指定-timeout 0,并且集线器将永远不会释放该节点。

  • browserTimeout 在集线器上,您也可以设置-browserTimeout 60可以使节点愿意在浏览器中挂起的最长时间为60秒。

  • timeout 30 (300 is default) The timeout in seconds before the hub automatically releases a node that hasn't received any requests for more than the specified number of seconds. After this time, the node will be released for another test in the queue. This helps to clear client crashes without manual intervention. To remove the timeout completely, specify -timeout 0 and the hub will never release the node.
  • browserTimeout On the hub you can also set -browserTimeout 60 to make the maximum time a node is willing to hang inside the browser 60 seconds.

这是我的有限了解


  • 超时-此值表示网格在处理特定测试之前应等待多长时间会话(一个特定的正在运行的测试用例)过时,以便可以清理该特定的测试会话并释放插槽,以便其他一些测试用例基本上可以在节点上执行。假设您正在Eclipse中运行测试用例,然后单击RED按钮并突然结束测试用例,则此参数相关。那时,客户端(您的测试用例)还没有向遥控器发送结束会话信号。因此,此会话已过时,网格必须清理此孤立会话。

  • browserTimeout -此值表示网格应保留多长时间请等待一段时间,然后再将特定的测试会话(特定的正在运行的测试用例)视为过时的,这是由于浏览器被挂起(可能是由于浏览器崩溃或由于冻结了浏览器的Web应用程序上的恶意javascript)。这里要注意的重要一点是客户端(从您的IDE或持续集成工具(例如,Jenkins等)中运行的测试用例)仍处于活动状态,但其浏览器没有响应。

  • timeout - This value represents how long should the Grid wait before it treats a particular test session (a particular running test case) as stale, so that that particular test session can be cleaned up and the slot released so that some other test case can basically execute on the node. This parameter is relevant when lets say you are running a test case from within eclipse and you click on the RED button and end your test case abruptly. At that time the client (your test case) hasn't sent a "end-session" signal to the remote. So this session is stale and the grid has to clean up this orphan session.
  • browserTimeout - This value represents how long should the Grid wait before it treats a particular test session (a particular running test case) as stale, due to the browser getting hung (maybe due to a browser crash or due to a rogue javascript on the web application which has frozen the browser). Here the important thing to note is that the client (the test case running from within your IDE or a Continuous Integration tool such as Jenkins for e.g.,) is still active but its the browser that has got un-responsive.

因此,为了保护您的执行免受客户端崩溃而导致的孤立测试会话的影响,请使用 timeout 并使用 browserTimeout 来保护您的网格免受冻结的浏览器的攻击,该浏览器拒绝返回并导致停滞的测试执行。

So to safe guard your executions from orphaned test sessions due to client crashes use timeout and use browserTimeout to safe guard your grid from frozen browsers which refuses to return back and causes stalled test executions.