0

I'm implementing a networking system in JavaScript (frontend) that will push the requests in a custom queue when there is no internet. The requests will be done, in the exact order, once the computer is re-connected.

The issue I'm having is that if I do the requests one by one, it might take very long to complete them all, and a browser can easily handle multiple requests at the same time.

My question is how can I push as many network request I can without overloading the browser with too many requests? Is there a common JS property that can be used, or something I can use to optimize the number of requests I can simultaneously do without overloading the browser?

halfer
  • 19,824
  • 17
  • 99
  • 186
Cyril N.
  • 38,875
  • 36
  • 142
  • 243
  • Likely dupe? https://stackoverflow.com/questions/561046/how-many-concurrent-ajax-xmlhttprequest-requests-are-allowed-in-popular-browse – mplungjan Jan 17 '21 at 14:42
  • Even detecting network connectivity is difficult and uncertain. – Pointy Jan 17 '21 at 14:49

0 Answers0