Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upload of larger videos stucks with slower Internet connections #88

Closed
DZenker opened this issue Nov 14, 2022 · 10 comments
Closed

Upload of larger videos stucks with slower Internet connections #88

DZenker opened this issue Nov 14, 2022 · 10 comments
Labels
bug Something isn't working

Comments

@DZenker
Copy link

DZenker commented Nov 14, 2022

Describe the bug
The video upload stucks with larger files if done with a slower internet connection (i.e. at home office): the save button remains in its disabled state even after the complete transfer of the video, and as a result there is no way to finalize the video upload step. For instance, upload of a approx. 35 MB video file succeeds, but all video files larger than approx. 50 MB stuck.
In contrast, I tried this from the university network (with faster upload speed compared to my home office), and in this scenario it's working as the save button is enabled after transfer of the video has been finished (even for videos > 1 GB). Thus, maybe this is caused by some kind of timeout, when the upload speed is too low and the upload process takes too long.

To Reproduce
Steps to reproduce the behavior:

  1. Click on button 'Upload Event'
  2. Select a larger video file (approx. 50 MB and larger)
  3. Video will be completely uploaded (verified by task manager)
  4. The save-button remains disabled and there's no way to proceed.

Expected behavior
After complete upload of the video file, the save button should get enabled to proceed.

Environment (please complete the following information):

Additional context
Already described here.

@DZenker DZenker added the bug Something isn't working label Nov 14, 2022
@dagraf
Copy link

dagraf commented Dec 14, 2022

I did some tests with our platform and can only partly reproduce the bug (see below).

Our ILIAS-Next (ILIAS: v7.11 2022-06-2, Opencast: 11, OC-Plugin: 5.0.0):
Bug does exist. Exactly and reliably after 30 seconds the progress bar of the upload gets stuck.

Our Community-ILIAS (ILIAS: v7.16 2022-11-24, Opencast: 11, OC-Plugin: 5.0.0):
Bug does NOT exist.

@dagraf
Copy link

dagraf commented Dec 14, 2022

After having updated our ILIAS-Next to the latest Version (v7.16 2022-11-24) the bug does still exist. Seems updating ILIAS does not solve the problem.

But I made a new observation on our ILIAS-Next: When I upload a video (which has an upload time shorter than 30 seconds), the "Save" button remains deactivated directly after the progress bar indicates that the upload is finished. It takes some more seconds (see screencast; handstopped: 5-15 seconds; I guess depending on the size of the video) until the "Save" button gets activated.

This behavior does NOT exist on our Community-ILIAS.

OC-Plugin.Upload-Bug.20221214.mp4

@DZenker
Copy link
Author

DZenker commented Dec 14, 2022

We are current running the latest ILIAS version (v7.16 2022-11-24), and the bug does still exist, too!

Are there any further differences between your NEXT and Community ILIAS, e.g. PHP version?

@dagraf
Copy link

dagraf commented Dec 14, 2022

Newest finding: When slowing internet speed to "Regular 4G" the bug does also appear on Community-ILIAS.

@okaufman
Copy link
Contributor

When checking in Dev-tools of the Browser there is only one "chunk" present. The POST Method is only called once
Bildschirmfoto 2022-12-14 um 14 58 05

If the upload is successful there are several calls to the POST Method
Bildschirmfoto 2022-12-14 um 14 58 50

@DZenker
Copy link
Author

DZenker commented Dec 15, 2022

But I made a new observation on our ILIAS-Next: When I upload a video (which has an upload time shorter than 30 seconds), the "Save" button remains deactivated directly after the progress bar indicates that the upload is finished. It takes some more seconds (see screencast; handstopped: 5-15 seconds; I guess depending on the size of the video) until the "Save" button gets activated.

I just tested it with different sized videos: i cannot reproduce this, regardless of whether the upload takes a few seconds or minutes. The save button is getting activated more or less immediately.

@dagraf
Copy link

dagraf commented Dec 15, 2022

I did a retest with the Fix #122: The bug does not exist anymore also when I limit connection speed to "Regular 4G". So everything fine there.

But now (at my home with activated vpn) the upload of a 200 MB video lasts hand stopped 16 seconds (which is still better than the 39 seconds it takes me in the 'old' plugin). Before the fix it took only 7 seconds. I think it would be worthwhile to look for a better compromise between supporting slower internet connections and taking care of fast uploads. Do you have a suggestion here, @chfsx ?

@DZenker
Copy link
Author

DZenker commented Dec 16, 2022

I've also tested with fix #122 (with increased chunk size of 20 MB) and can confirm that it is working now!

Concerning the upload time: I've tested an upload of a 1.8 GB video file with an upstream bandwidth of around 12 MBit/s, which was completed after ca. 22 minutes. This is close to the expected time of 20 min transferring 1.8 GB with 1.5 MB/s under optimal conditions.

@chfsx
Copy link
Contributor

chfsx commented Dec 21, 2022

#122 is updated to use 20MB as default chunk size

@dagraf
Copy link

dagraf commented Dec 21, 2022

I did a retest after deploying #122: It works and uploads seem to be slightly faster than with the 'old' chunk-upload. Therefore I close this issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants