Failed to load resource: net::ERR_FILE_NOT_FOUND u

2019-05-25 07:13发布

I have a problem uploading files bigger than 500Mb.

I created a plunker file with error code: https://plnkr.co/edit/vKHNkUuVX1RrMcZ6Ezhc?p=preview

var request = new XMLHttpRequest();
request.open("POST", "/uploadFile");
request.send(formData);

request.addEventListener("progress", function(evt) {
  if (evt.lengthComputable) {
    console.log(evt.loaded / evt.total);
  } else {
    console.log('Undefined percent...');
  }
}, false);
request.addEventListener("load", function(evt) {
  console.error(evt);
}, false);
request.addEventListener("error", function(evt) {
  console.error(evt);
}, false);

To reproduce the error:

  1. Open Chrome with link of plunker file.
  2. Open inspector console (F12).
  3. Upload file with size between 300Mb and 500Mb.
  4. Server response with error, but the code try to upload the file selected.
  5. Upload file bigger than 200Mb.
  6. Get an net::ERR_FILE_NOT_FOUND from client code, the call not arrive to server.

Best regards and thanks.

0条回答
登录 后发表回答