-
-
Notifications
You must be signed in to change notification settings - Fork 4.2k
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
[oc] Enable chunking for bigger files in authenticated web upload #7056
Merged
blizzz
merged 1 commit into
master
from
oc-28415-enable-chunking-in-authenticated-web-upload
Nov 10, 2017
Merged
[oc] Enable chunking for bigger files in authenticated web upload #7056
blizzz
merged 1 commit into
master
from
oc-28415-enable-chunking-in-authenticated-web-upload
Nov 10, 2017
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This commit adds chunked uploads in the Web UI (for authenticated users, but not for public uploads). To do that the server endpoint used by the uploader is changed from WebDAV v1 to WebDAV v2. The chunking itself is done automatically by the jQuery-File-Upload plugin when the "maxChunkSize" parameter is set; in "fileuploadchunksend" the request is adjusted to adapt the behaviour of the plugin to the one expected by "uploads/" in WebDAV v2. The chunk size to be used by the Web UI can be set in the "max_chunk_size" parameter of the Files app configuration. By default it is set to 10MiB. Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
5d3b31c
to
cd8d13b
Compare
Codecov Report
@@ Coverage Diff @@
## master #7056 +/- ##
============================================
- Coverage 50.61% 50.61% -0.01%
- Complexity 24297 24298 +1
============================================
Files 1577 1577
Lines 92922 92931 +9
Branches 1359 1359
============================================
+ Hits 47036 47040 +4
- Misses 45886 45891 +5
|
MorrisJobke
approved these changes
Nov 7, 2017
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Tested and works 👍
blizzz
approved these changes
Nov 10, 2017
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Tested, works +1
Closed
This was referenced Nov 10, 2020
MorrisJobke
pushed a commit
to nextcloud/documentation
that referenced
this pull request
Nov 10, 2020
documenting nextcloud/server#7056 Signed-off-by: Sascha Wiswedel <sascha.wiswedel@nextcloud.com>
MorrisJobke
pushed a commit
to nextcloud/documentation
that referenced
this pull request
Nov 10, 2020
documenting nextcloud/server#7056 Signed-off-by: Sascha Wiswedel <sascha.wiswedel@nextcloud.com>
MorrisJobke
pushed a commit
to nextcloud/documentation
that referenced
this pull request
Nov 10, 2020
documenting nextcloud/server#7056 Signed-off-by: Sascha Wiswedel <sascha.wiswedel@nextcloud.com>
MorrisJobke
pushed a commit
to nextcloud/documentation
that referenced
this pull request
Nov 10, 2020
documenting nextcloud/server#7056 Signed-off-by: Sascha Wiswedel <sascha.wiswedel@nextcloud.com>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Imported from owncloud/core#28415.
This pull request adds chunked uploads in the Web UI (for authenticated users, but not for public uploads). To do that the server endpoint used by the uploader is changed from WebDAV v1 to WebDAV v2. The chunking itself is done automatically by the jQuery-File-Upload plugin when the
maxChunkSize
parameter is set; infileuploadchunksend
the request is adjusted to adapt the behaviour of the plugin to the one expected by uploads/ in WebDAV v2.The chunk size to be used by the Web UI can be set in the
max_chunk_size
parameter of the Files app configuration. By default it is set to 10MiB.Differences with the original pull request:
port
is not removed; removing it is not needed for the other changes (it was just an unrelated cleanup due to the port being already included inhost
), and it could be needed by some user of the client object, so it feels safer to keep it.core/js/config.php
was removed in Remove config.php for oc.js #1961 after its functionality was replaced with lib/private/Template/JSConfigHelper.php; the changes are not needed in the new code.apps/files/lib/App.php
was adapted due to the settings array now (after the configuration changes mentioned above) being encoded in JSON instead of being a plain PHP array.This pull request (like the original one, if I am not mistaken) is not bug free. If an upload is cancelled it is not possible to upload other files until the page is reloaded, and there are also some issues with the progress bar when several files are uploaded at once and one of them fails.
However, I would prefer to merge this as is now and fix the bugs later to be able to import other pull requests based on this one in an easier way.