-
-
Notifications
You must be signed in to change notification settings - Fork 3.6k
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
[5.3] Chunked download for the Joomla Update process #43489
base: 5.3-dev
Are you sure you want to change the base?
[5.3] Chunked download for the Joomla Update process #43489
Conversation
That restoring mirrors is not enough just removing |
Ok thanks - i will look into it further. However in my tests i have all the expected download servers in the array. |
administrator/components/com_joomlaupdate/src/Model/UpdateModel.php
Outdated
Show resolved
Hide resolved
administrator/components/com_joomlaupdate/tmpl/update/download.php
Outdated
Show resolved
Hide resolved
administrator/components/com_joomlaupdate/tmpl/update/download.php
Outdated
Show resolved
Hide resolved
Thanks a lot! Co-authored-by: Brian Teeman <brian@teeman.net>
It's not about the availability of all the links, but about processing them. Initially, the update, including mirrors, worked like this: Then the logic was corrected:
Getting the final link through headers is the right approach, but it should consider mirrors exactly in the first step. So the correct algorithm is:
Let me tell you about the timeout again. I took the timeout time based on standard PHP settings. Honestly, it might have been better to first complete #43489 and adopt it to restore the update functionality (for example, the timeout could have been made a setting, and then users with slow speeds could just increase the timeout values after changing the php.ini settings), and then seriously approach the redesign. If you approach the update functionality intelligently, then you need to revise the principle.
If something goes wrong but the archive has been downloaded, you can simply restart step 3. However, in the case of chunks, it's not that simple. And the main problem is this: I hope this will be useful, and thank you for your work. |
Another option is to completely abandon the iteration over all mirrors and give users the choice of which mirror to download from. For example, I could choose Github on my end, while someone else might keep Amazon. Someone else might choose the third mirror. Such an approach would eliminate the need to iterate through mirrors and give users the option. This way, you can comfortably attempt to implement chunks while reducing the script execution time. |
Thanks again Co-authored-by: Brian Teeman <brian@teeman.net>
* | ||
* @return void | ||
* | ||
* @since 2.5.4 |
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.
* @since 2.5.4 | |
* @since __DEPLOY_VERSION__ |
/** | ||
* Start the installation of the new Joomla! version | ||
* | ||
* @return void | ||
* | ||
* @since 2.5.4 | ||
*/ | ||
public function install() | ||
public function install(): void |
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.
public function install(): void | |
public function install() |
b/c break
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.
Component's not subject to b/c policy?
This pull request has been automatically rebased to 5.3-dev. |
Please read the instructions carefully! Needs a new Joomla Installation and access to the joomla files (no Patch Tester)
Summary of Changes
Based on the #39280 from @nikosdion - thank you!
Testing Instructions
Cannot be tested using Patch Tester as there are NPM resources changed and need the joomla package to build (use prebuilt packages)
You need access to your joomla installation (e.g. FTP)
this way an update to 5.1.0 stable will be proposed since EXTRA_VERSION is on alpha1-dev (if not set it to alpha1-dev)
you cannot update to 5.2.0 versions since there are no packages yet.
For experts only:
You can simulate an unavailable downloadserver with a setting in /etc/hosts of your server:
0.0.0.1 s3-us-west-2.amazonaws.com
and/or
0.0.0.1 objects.githubusercontent.com
REMEMBER: Your installation will be overwritten by the update! After the update your site will be on 5.1!
Actual result BEFORE applying this Pull Request
Expected result AFTER applying this Pull Request
Link to documentations
Please select:
Documentation link for docs.joomla.org:
No documentation changes for docs.joomla.org needed
Pull Request link for manual.joomla.org:
No documentation changes for manual.joomla.org needed