intern icon indicating copy to clipboard operation
intern copied to clipboard

Add ability to retry command requests to remote browsers

Open jason0x43 opened this issue 7 years ago • 4 comments

Sometimes commands sent to remote browsers timeout due to transient network flakiness. (See #905.) In those cases, it would be helpful if Intern would try re-sending a command some limited number of times.

This functionality might work best in Leadfoot, or possibly in ProxiedSession. The goal would be for network sends to be transparently retried some number of times (which may or may not be initially configurable).

jason0x43 avatar May 30 '18 13:05 jason0x43

The frequency of timeouts when connected to BrowserStack has gotten a bit silly at this point.

jason0x43 avatar Jan 29 '20 21:01 jason0x43

A potential fix has been pushed in 7b7b110. This commit adds retry functionality for all requests made from Node. Only two classes of failures lead to retries: ETIMEDOUT (a TCP connection couldn't be established) or ECONNRESET (a connection was forcibly closed). By default, Intern will retry a request twice. The common/request.request now understands a retries option that will let this be configured on a per-request basis.

jason0x43 avatar Jan 30 '20 16:01 jason0x43

Is there any update on this fix, I am still noticing ETIMEDOUT Error on browserstack.

nagadinesh-git avatar Mar 09 '20 18:03 nagadinesh-git

This is in Intern master, but hasn't yet been backported to Intern 4.x (@theintern/common, specifically).

jason0x43 avatar Mar 09 '20 20:03 jason0x43