? Pending

User tests: Successful: Unsuccessful:

avatar mbabker
mbabker
30 Nov 2017

Summary of Changes

This is an enhancement of #18547 to introduce support for multiple download sources (AKA mirrors) to the update server library. See the original PR for all the basics.

I have made a couple of core tweaks to the concept to allow us to be minimally disruptive to past releases while also enable us to expand the API and be able to implement other missing features in the update system. In short:

  • Introduces a new <downloadsource> tag to be used under the <downloads> tag, this is different than the original PR which tweaked the update library to support multiple <downloadurl> tags
    • In thinking about that implementation more, I started to worry that all currently released Joomla versions might not cope very well with having multiple <downloadurl> tags which would cause more issues in serving updates, so I think a new tag is going to be the absolute safest option
  • Introduces a new PHP class acting as a data object to give a standardized PHP definition of the new <downloadsource> tag
    • This will also allow us to standardize and implement the additional attributes that are present on the tag but unused
  • Conceptually doing a "soft" reservation on the tag attributes and defining standardized values allows us to revisit PRs like #11497 and work on optimizing the packages served through the update component for the various update/install paths instead of always serving the largest of the packages we have (so the 3.8.1 to 3.8.2 update could receive the optimized 1.07 MB ZIP file instead of requiring the full 11.37 MB ZIP file, less bandwidth expense and a smaller number of files to process in the update cycle, everyone wins)

Testing Instructions

With the patch applied, go into the update component, set the update channel to "Custom URL" and use the URL https://developer.joomla.org/test-update-server/list_sts.xml as your server. Then try to update Joomla (this will use a nightly build, so it WILL undo the changes from this patch). The update should work.

Note this server is purposefully provisioned so that it should fail on the first two download attempts, the first using the existing <downloadurl> tag and the second the first element of the new download sources array. So a successful update purposefully only happens after a couple of failures to validate the fallback behavior works.

Documentation Changes Required

The update server documentation should be expanded to document the new tag/options.

Votes

# of Users Experiencing Issue
1/1
Average Importance Score
5.00

avatar mbabker mbabker - open - 30 Nov 2017
avatar mbabker mbabker - change - 30 Nov 2017
Status New Pending
avatar joomla-cms-bot joomla-cms-bot - change - 30 Nov 2017
Category Administration com_installer com_joomlaupdate Libraries
avatar Septdir
Septdir - comment - 2 Dec 2017

I tested it. Updating joomla is working.
I like this realization. @mbabker at you it was excellent it turned out to unite and to improve all offered variants of realization

P.S I'm attaching plg_system_testtalt_1.0.0.zip for testing com_installer.
Update manifest https://joomla.septdir.ru/updateserver/pluginalt.xml

avatar effrit
effrit - comment - 2 Dec 2017

Also tested it.
Successfully updated from the local server, which normally can not get the updates due to Internet provider blocking the sub-domain of Amazon.
@mbabker, thank you very much!

avatar franz-wohlkoenig
franz-wohlkoenig - comment - 2 Dec 2017

@Septdir @effrit please mark your Test as successfully:

  • open Issue Tracker
  • Login with your github-Account
  • Click on blue "Test this"-Button above Authors-Picture
  • mark your Test as successfully
  • hit "submit test result"
avatar Septdir
Septdir - comment - 2 Dec 2017

@franz-wohlkoenig This PR is an enhancement of my #18547 I'm not sure whether I can mark Test as successfully

P.S At night, I did't test com_installer. Now tested. Everything works as it should.

avatar pavluk pavluk - test_item - 2 Dec 2017 - Tested successfully
avatar pavluk
pavluk - comment - 2 Dec 2017

I have tested this item successfully on 9ce52d7


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/18926.

avatar effrit effrit - test_item - 2 Dec 2017 - Tested successfully
avatar effrit
effrit - comment - 2 Dec 2017

I have tested this item successfully on 9ce52d7


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/18926.

avatar franz-wohlkoenig franz-wohlkoenig - change - 2 Dec 2017
Status Pending Ready to Commit
avatar franz-wohlkoenig
franz-wohlkoenig - comment - 2 Dec 2017

Ready to Commit after two successful tests.

avatar wilsonge wilsonge - change - 2 Dec 2017
Status Ready to Commit Fixed in Code Base
Closed_Date 0000-00-00 00:00:00 2017-12-02 17:11:25
Closed_By wilsonge
Labels Added: ?
avatar wilsonge wilsonge - close - 2 Dec 2017
avatar wilsonge wilsonge - merge - 2 Dec 2017
avatar wilsonge
wilsonge - comment - 2 Dec 2017

Nice work. Thanks @mbabker !

avatar ReLater
ReLater - comment - 1 Jun 2019

The update server documentation should be expanded to document the new tag/options.

@Septdir @mbabker

I would like to update the documentation but first want to go sure if the following example code is correct (your manifest examples above aren't available anymore). And because it uses the Joomla package. Thank you!

<updates>
	<update>
		<name>Joomla! 3.6</name>
		<description>Joomla! 3.6 CMS</description>
		<element>joomla</element>
		<type>file</type>
		<version>3.6.5</version>
		<infourl title="Joomla!">https://www.joomla.org/announcements/release-news/5693-joomla-3-6-5-released.html</infourl>
		<downloads>
			<downloadurl type="full" format="zip">https://downloads.joomla.org/cms/joomla3/3-6-5/Joomla_3.6.5-Stable-Update_Package.zip</downloadurl>

			<downloadsource type="full" format="zip">https://example.com/Joomla_3.6.5-Stable-Update_Package.zip</downloadsource>
			<downloadsource type="full" format="zip">https://other.example.com/Joomla_3.6.5-Stable-Update_Package.zip</downloadsource>

		</downloads>
		<tags>
			<tag>stable</tag>
		</tags>
		<maintainer>Joomla! PLT</maintainer>
		<maintainerurl>https://www.joomla.org</maintainerurl>
		<section>STS</section>
		<targetplatform name="joomla" version="3.[234567]" />
		<php_minimum>5.3.10</php_minimum>
	</update>
</updates>
avatar wilsonge
wilsonge - comment - 1 Jun 2019

Add a Comment

Login with GitHub to post a comment