'Query regarding the upload of multiple files in different browsers in Angular (inconsistent behaviors)

In my Angular project, I have a simple multiple file upload:

<input
  type="file"
  class="display-none"
  #file
  (change)="onFilesSelectedForUpload()"
  onclick="value = null"
  multiple
/>

Based on some investigations, most browsers (Chrome, Firefox, Edge) have a limit of 6 connections per hostname reference and I was expecting the same behaviour from them, but it did not happen.

  • Chrome

When there are 6 files being uploaded (each with a size of 100 MB), and I try to access the list of groups, the last request is not processed and it stays in pending status. The screenshot shows what the Network tab looks like -> Check Image Here

But when a file is successfully uploaded, and the number of files in progress goes to 5, then the request is processed and the list of groups is displayed.

  • Edge

I repeated the same scenario using Microsoft Edge and I encountered the same behavior.

  • Mozilla Firefox

Using Mozilla, I observed an unstable behavior. When I upload the same 6 files, the next request (to display the list of groups) is not processed. In the first test, groups are displayed when there were 5 files in progress, in the second test only when there was only 1 file in progress, and in the third test when there were 4 files in progress.

I would highly appreciate your help with any information on why this is happening and what could be the possible cause.

Thank you.



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source