This is a migrated thread and some comments may be shown as answers.

Problems with multi-file upload and HTTP/2

11 Answers 169 Views
Upload
This is a migrated thread and some comments may be shown as answers.
Gary
Top achievements
Rank 1
Gary asked on 11 Aug 2020, 07:40 PM

Hello,

  We are having a problem uploading multiple files on a server running HTTP/2.  Single files upload fine.  I used the "batch" property and that seems to work ok since it's one request.  We disabled HTTP/2 and went back to HTTP/1.1.  Everything seemed to work fine.
I downloaded the newest trial version it is still has the problem. Is there any way around this issue without using the "batch" property?

Thanks in advance!

11 Answers, 1 is accepted

Sort by
0
Martin
Telerik team
answered on 13 Aug 2020, 04:24 PM

Hello Gary,

Just to make the scenario clear. You are selecting several files for uploading, and unless you have the batch configuration set to true, the upload fails. Could you please let me know if there are any errors on the console? Also, if there are any specifics in the Upload configuration, kindly provide an example where I can test the behavior.

Looking forward to your reply.

Regards,
Martin
Progress Telerik

0
Gary
Top achievements
Rank 1
answered on 13 Aug 2020, 04:41 PM

Hi Martin,

Yes, we are selecting multiple files for upload at one time.  Yes if I put it into batch mode it works.  If it uploads the files separately at least one fails.  The errors that are received as a response is "Request timeout".  We increased the executionTimeout, but that just allowed the file that is having a problem to fail more gracefully and move on to the next file.  After the upload is complete, I can press the "retry" button the failed file and it works fine.
I have tried the "autoRetry", "concurrent" with "chunkSize" but only the batch option works since the upload is performed in one request.
Here is the super simple code that we are using to perform the upload:
$(selector).kendoUpload({
                async: {
                    saveUrl: '/' + window.location.pathname.split('/')[1] + '/FileUpload.ashx',
                    autoUpload: true
                },
                localization: {
                    select: base64Obj.decode(localizedStrings.selectBtn),
                    uploadSelectedFiles: base64Obj.decode(localizedStrings.uploadSelectedFiles),
                    dropFilesHere: base64Obj.decode(localizedStrings.dropFilesHere),
                    statusUploading: base64Obj.decode(localizedStrings.statusUploading),
                    statusUploaded: base64Obj.decode(localizedStrings.statusUploaded),
                    statusFailed: base64Obj.decode(localizedStrings.statusFailed)
                },
                //showFileList: true,
                multiple: true,
                select: onSelectFiles,
                upload: onUploadFiles,
                success: onSuccessFiles,
                complete: onCompleteFiles
            });

Please let me know if you need anymore information.

Thanks!

Gary

0
Martin
Telerik team
answered on 17 Aug 2020, 02:04 PM

Hello Gary,

Thank you for the additional explanation. 

Attached you will find a small project along with a video how it behaves on my side. You can see that I am able to select and upload multiple files successfully. Could you modify the project to reproduce the issue, or tell me if I am missing something?

Looking forward to your reply.

Regards,
Martin
Progress Telerik

0
Gary
Top achievements
Rank 1
answered on 18 Aug 2020, 01:15 PM

Hi Martin,

  We are using .Net Web Forms (not MVC) with an HTTP handler as the upload handler.  Maybe in has to do with that?

Gary

0
Attila Antal
Telerik team
answered on 20 Aug 2020, 11:17 AM

Hi Gary,

The multiple property will only allow the user to select multiple files. For uploading them in bulk you will need to enable the batch for it.

Kind regards,
Attila Antal
Progress Telerik

Virtual Classroom, the free self-paced technical training that gets you up to speed with Telerik and Kendo UI products quickly just got a fresh new look + new and improved content including a brand new Blazor course! Check it out at https://learn.telerik.com/.

0
Gary
Top achievements
Rank 1
answered on 20 Aug 2020, 12:16 PM

Hi Attila,

  Sorry I think you misunderstood the actual problem. Multiple does not work, batch does work on HTTP/2.  Martin from Telerik is helping me solve the problem.

Gary

0
Petar
Telerik team
answered on 24 Aug 2020, 06:34 AM

Hi Gary,

Does the file upload always fail with one and the same file? Or the file on which the upload process fails is a random one? If the file is the same, could the issue be related to its type or its size? Or maybe it could be a file-related issue? 

Can you send us a runnable example in which the reported behavior can be replicated? Also, can you provide the files with which you reproduce it? If you don't want to publicly share your files, you can submit a support ticket and we will check your example in it. 

Regards,
Petar
Progress Telerik

Virtual Classroom, the free self-paced technical training that gets you up to speed with Telerik and Kendo UI products quickly just got a fresh new look + new and improved content including a brand new Blazor course! Check it out at https://learn.telerik.com/.

0
OfficeHeart
Top achievements
Rank 1
answered on 19 Nov 2020, 06:54 PM

We have a similar issue. Switching back to HTTP/1.1 works always fine. Using HTTP/2 uploads are sometimes 'paused' for a long time. It's almost impossible to reproduce. It just happens sometimes.

The bigger the file (eg. 500MB+), the more likely it will go wrong.

0
Martin
Telerik team
answered on 23 Nov 2020, 02:27 PM

Hello Martin, 

I tested the behavior in the project from 17th August and I was unable to upload large files ( 100mb + ). I managed to resolve the problem using the steps from this GitHub issue.

Let me know how that works for you.

Regards,
Martin
Progress Telerik

Virtual Classroom, the free self-paced technical training that gets you up to speed with Telerik and Kendo UI products quickly just got a fresh new look + new and improved content including a brand new Blazor course! Check it out at https://learn.telerik.com/.

0
OfficeHeart
Top achievements
Rank 1
answered on 24 Nov 2020, 09:02 AM

Hi Martin,

The web.config settings are fine. The maxRequestLength and maxAllowedContentLength allow 2GB.
The strange thing is that it sometimes works like a charm and sometimes it doesn't.

The only error we get is a HTTP2 protocol error in the browser. Rebooting the webserver (windows 2019 + iis) seems to work at lease for a short time. Once the error occurs, it occurs of different computers, different browsers. The only way to solve this error for a short period of time is to reboot or to switch back to HTTP/1.1.

The application is a ASP.net 4.8 application.

We spend a lot of time in trying to create a sample application or to reproduce the issue on command, but no luck so far.

Regards,

Martin

0
Martin
Telerik team
answered on 25 Nov 2020, 03:25 PM

Hello Martin,

The link I shared doesn't involve changes only in the web.config, but also in Startup.cs. Please refer to step 2 from the GitHub issue.

After following those steps, uploading of large file is consistent and working as expected. Having that said, without being able to test the behavior you are experiencing, it will be hard for me to suggest a solution. If you manage to reproduce it in a project, I will be happy to debug it.

Regards,
Martin
Progress Telerik

Virtual Classroom, the free self-paced technical training that gets you up to speed with Telerik and Kendo UI products quickly just got a fresh new look + new and improved content including a brand new Blazor course! Check it out at https://learn.telerik.com/.

Tags
Upload
Asked by
Gary
Top achievements
Rank 1
Answers by
Martin
Telerik team
Gary
Top achievements
Rank 1
Attila Antal
Telerik team
Petar
Telerik team
OfficeHeart
Top achievements
Rank 1
Share this question
or