What kind of network error is Chrome encountering when 'Status = (failed)' and 'Type = undefined'

后端 未结 7 1337
情歌与酒
情歌与酒 2020-12-29 21:57

Sometimes I randomly see network requests from Chrome failing with Status = \'(failed)\' (status code 0 from the request object in JavaScript) and the response type as \'und

7条回答
  •  抹茶落季
    2020-12-29 22:19

    We had exactly this issue with an application reaching an API we control. It took a while for me to realize that slower clients were not seeing the issue, whereas faster clients (and pages with more requests) were.

    It turned out that our HA Proxy was rate limiting requests on our frontend. Once we raised the limit from the value of 20 we had set up to something around 100, we no longer had the issue.

    So it's possible you're getting blocked by something along the request pathway, potentially a proxy or load balancer or even a firewall.

提交回复
热议问题