|
|
| (10 intermediate revisions by 5 users not shown) |
| Line 28: |
Line 28: |
|
| |
|
| The Service URL needs to incorporate data in these dimensions so as to reduce the complexity of the processing on the client side: | | The Service URL needs to incorporate data in these dimensions so as to reduce the complexity of the processing on the client side: |
| | * service URL schema version (so we can change it in the future) |
| * app name | | * app name |
| * app locale
| |
| * app version | | * app version |
| * app buildid (for distinguishing between nightlies on a "tester" build stream for example) | | * app buildid (for distinguishing between nightlies on a "tester" build stream for example) |
| * app buildtarget | | * app buildtarget |
| | * app locale |
| | * aus channel |
| | * distribution name |
| | * distribution version |
| | |
| | e.g., |
|
| |
|
| e.g.
| | <tt>/update/3/Firefox/3.0a8pre/2007083015/Darwin_x86-gcc3/en-US/default/Darwin%208.10.1/testpartner/1.0/update.xml</tt> |
|
| |
|
| <tt>/firefox/1.0.3.20050414/i586-pc-msvc/en-US/update.xml</tt>
| | See app.update.url below for the template used in creating the Service URL. |
|
| |
|
| =The Updates File= | | =The Updates File= |
|
| |
|
| update.xml is an XML file that tells about available updates. It is formatted
| | See [[Software_Update:updates.xml_Format]] for documentation of this format. |
| like this:
| |
| | |
| <tt><pre>
| |
| <?xml version="1.0"?>
| |
| | |
| <updates>
| |
| <update type="minor" version="1.0.4" extensionversion="1.0">
| |
| <patch type="partial" url="http://www.foo.com/1.0.4-partial.xpi"
| |
| hashfunction="" hashvalue="" size=""/>
| |
| <patch type="complete" url="http://www.foo.com/1.0.4-complete.xpi"
| |
| hashfunction="" hashvalue="" size=""/>
| |
| </update>
| |
| ..
| |
| <update type="major" version="1.1.2" extensionversion="1.1">
| |
| <patch type="complete" url="http://www.foo.com/1.1.2-complete.xpi"
| |
| hashfunction="" hashvalue="" size=""/>
| |
| </update>
| |
| </updates>
| |
| </pre></tt>
| |
| | |
| The application should provide a preference setting that can be set to hold
| |
| the application within one version range, e.g. within 1.0.x, never updating
| |
| to the newest major version but only installing incremental security updates.
| |
| | |
| The <updates> list specifies the set of updates that can be downloaded and
| |
| installed and may play a role in updating the application.
| |
| | |
| Each "partial" update is a diff of the new version from the previous version.
| |
| If there are several "partial" updates available, they are all downloaded and
| |
| installed in order. [Note: Initially we may only install a single patch and
| |
| then rely on a subsequent update check to determine that there are more patches
| |
| available and install them at that time.]
| |
| | |
| Before a collection of updates is downloaded and installed, the size attribute
| |
| for each patch is read to determine file size, and if the sum of the patch | |
| sizes is found to be greater than the size of the "complete" patch (which is
| |
| a jar file whose contents are only file additions, removals and replaces, no
| |
| file patches), then the "complete" file is downloaded.
| |
| | |
| We only supply "complete" updates to major versions since we cannot easily pick
| |
| a version to diff against off of a previous version series, e.g. do we diff
| |
| off 1.1.4? What if we do a security release 1.1.5 further down the line? It
| |
| is simpler to make users doing major upgrades redownload the bundle.
| |
| | |
| This system intrinsically supports updates to the updater - if a point in time
| |
| is reached at which we can no longer fully update a user to the newest version,
| |
| we can provide a series of updates that take them to a version that can then
| |
| be updated further, e.g.
| |
| | |
| User is using 1.1.1
| |
| Newest version is 1.5.9 but due to a bug in the updater in all versions older
| |
| than 1.1.4, the user cannot update directly to 1.5.9.
| |
| | |
| The update.xml file for the 1.1.1 user might look something like this:
| |
| | |
| <tt><pre>
| |
| <?xml version="1.0"?>
| |
| | |
| <updates>
| |
| <update type="minor" version="1.1.2" extensionversion="1.1">
| |
| <patch type="partial" url="http://www.foo.com/1.1.2-partial.xpi"
| |
| hashfunction="" hashvalue="" size=""/>
| |
| <patch type="complete" url="http://www.foo.com/1.1.2-complete.xpi"
| |
| hashfunction="" hashvalue="" size=""/>
| |
| </update>
| |
| <update type="minor" version="1.1.3" extensionversion="1.1">
| |
| <patch type="partial" url="http://www.foo.com/1.1.3-partial.xpi"
| |
| hashfunction="" hashvalue="" size=""/>
| |
| <patch type="complete" url="http://www.foo.com/1.1.3-complete.xpi"
| |
| hashfunction="" hashvalue="" size=""/>
| |
| </update>
| |
| <update type="minor" version="1.1.4" extensionversion="1.1">
| |
| <patch type="partial" url="http://www.foo.com/1.1.4-partial.xpi"
| |
| hashfunction="" hashvalue="" size=""/>
| |
| <patch type="complete" url="http://www.foo.com/1.1.4-complete.xpi"
| |
| hashfunction="" hashvalue="" size=""/>
| |
| </update>
| |
| </updates>
| |
| | |
| </pre></tt>
| |
| | |
| And for the 1.1.4 user like so:
| |
| | |
| <tt><pre>
| |
| <?xml version="1.0"?>
| |
| | |
| <updates>
| |
| <update type="minor" version="1.1.5" extensionversion="1.1">
| |
| <patch type="partial" url="http://www.foo.com/1.1.5-partial.xpi"
| |
| hashfunction="" hashvalue="" size=""/>
| |
| <patch type="complete" url="http://www.foo.com/1.1.5-complete.xpi"
| |
| hashfunction="" hashvalue="" size=""/>
| |
| </update>
| |
| <update type="major" version="1.5.9" extensionversion="1.5">
| |
| <patch type="complete" url="http://www.foo.com/1.5.9-complete.xpi"
| |
| hashfunction="" hashvalue="" size=""/>
| |
| </update>
| |
| </updates>
| |
| | |
| </pre></tt>
| |
| | |
| So the user of 1.1.1 will have the 1.1.2, 1.1.3, and 1.1.4 patches
| |
| downloaded and applied in that order. When they start the application the next
| |
| time, the application will recheck for updates using 1.1.4's enhanced bugfixed
| |
| updater, and discover 1.1.5 and the 1.5.9 major update.
| |
| | |
| This implies that the database that manages all of this version information
| |
| has to know that some updates can only apply to certain version (ranges).
| |
| | |
| | |
| On the client side:
| |
| We can have a [Update Details] button under menu: [Help] > [About Mozilla Firefox].
| |
| By clicking this button [[Update Details] we can present a tabluar view with the following columns:
| |
| 1. Updated Item
| |
| 2. Version
| |
| 3. Type { Security update or enhancement update...}
| |
| 4. Updated Item release date
| |
| 5. Updated date
| |
| 6. Updated by user ?
| |
|
| |
|
| = Preference Controls and State = | | = Preference Controls and State = |
| Line 174: |
Line 61: |
| <table border="1" cellspacing="0" cellpadding="3"> | | <table border="1" cellspacing="0" cellpadding="3"> |
| <tr><td>'''0'''</td> | | <tr><td>'''0'''</td> |
| <td>automatically download and install available updates for | | <td>automatically download updates for minor and major updates, regardless of incompatibilities that may arise with addons</td></tr> |
| minor releases, offer updates to major releases</td></tr>
| |
| <tr><td>'''1'''</td> | | <tr><td>'''1'''</td> |
| <td>automatically download and install available updates for | | <td>automatically download updates for minor and major releases, if no incompatibilities with addons are present, otherwise prompt</td></tr> |
| minor releases, do '''not''' offer updates to major releases</td></tr>
| |
| <tr><td>'''2'''</td> | | <tr><td>'''2'''</td> |
| <td>automatically download and install available updates for minor | | <td>automatically download updates for minor releases, prompt about major releases</td></tr> |
| ''and'' major releases</td></tr>
| |
| <tr><td>'''3'''</td> | | <tr><td>'''3'''</td> |
| <td>automatically download available updates for minor ''and'' | | <td>prompt about minor and major releases</td></tr> |
| major releases and prompt when ready for installation</td></tr>
| |
| <tr><td>'''4'''</td>
| |
| <td>automatically download available updates for minor releases '''only'''
| |
| prompt when ready for installation</td></tr>
| |
| </table> | | </table> |
| </blockquote> | | </blockquote> |
| Line 193: |
Line 73: |
| <blockquote> | | <blockquote> |
| <table border="1" cellspacing="0" cellpadding="3"> | | <table border="1" cellspacing="0" cellpadding="3"> |
| <tr><td>'''86400000'''</td><td>milliseconds between update checks</td></tr> | | <tr><td>'''86400'''</td><td>seconds between update checks</td></tr> |
| | </table> |
| | </blockquote> |
| | * <tt>app.update.timer</tt> |
| | <blockquote> |
| | <table border="1" cellspacing="0" cellpadding="3"> |
| | <tr><td>'''5000'''</td><td>milliseconds between app.update.interval expiry checks</td></tr> |
| </table> | | </table> |
| </blockquote> | | </blockquote> |
| * <tt>app.update.lastUpdateDate</tt> | | * <tt>app.update.silent</tt> |
| <blockquote> | | <blockquote> |
| <table border="1" cellspacing="0" cellpadding="3"> | | <table border="1" cellspacing="0" cellpadding="3"> |
| <tr><td>'''1114648397'''</td><td>seconds since epoch of last update time</td></tr> | | <tr><td>'''true'''</td><td>all update prompting should be suppressed</td></tr> |
| | <tr><td>'''false'''</td><td>show prompts to the user when there are events they should respond to</td></tr> |
| </table> | | </table> |
| </blockquote> | | </blockquote> |
| * <tt>app.update.timer</tt> | | * <tt>app.update.lastUpdateDate.background-update-timer</tt> |
| <blockquote> | | <blockquote> |
| <table border="1" cellspacing="0" cellpadding="3"> | | <table border="1" cellspacing="0" cellpadding="3"> |
| <tr><td>'''3600000'''</td> | | <tr><td>'''1114648397'''</td><td>seconds since epoch of last update time</td></tr> |
| <td>milliseconds between checks for update interval expiry, where expiry is defined by time since epoch (seconds) is greater than
| |
| <tt>app.update.lastUpdateDate</tt> + <tt>app.update.interval</tt></td></tr>
| |
| </table> | | </table> |
| </blockquote> | | </blockquote> |
| Line 213: |
Line 98: |
| <blockquote> | | <blockquote> |
| <table border="1" cellspacing="0" cellpadding="3"> | | <table border="1" cellspacing="0" cellpadding="3"> |
| <tr><td>'''http://aus.mozilla.org/update/firefox/%1%/%2%/%3%/update.xml'''</td></tr> | | <tr><td>'''https://aus2.mozilla.org/update/3/%PRODUCT%/%VERSION%/%BUILD_ID%/%BUILD_TARGET%/%LOCALE%/%CHANNEL%/%OS_VERSION%/%DISTRIBUTION%/%DISTRIBUTION_VERSION%/update.xml'''</td></tr> |
| <tr><td>%1% is the version, in FVF containing the build id; %2% is the | | <tr><td>'3' is the schema version<br/> |
| build target (OS+Architecture); %3% is the ab-CD locale</td></tr>
| | PRODUCT: App name (e.g., 'Firefox')<br/> |
| | VERSION: App version (e.g. '3.0a8pre')<br/> |
| | BUILD_ID: Build ID (e.g., '2007083015')<br/> |
| | BUILD_TARGET: Build target (e.g., 'Darwin_x86-gcc3')<br/> |
| | LOCALE: App locale (e.g., 'en-US')<br/> |
| | CHANNEL: AUS channel (e.g., 'default')<br/> |
| | OS_VERSION: Operating System version (e.g., 'Darwin%208.10.1')<br/> |
| | DISTRIBUTION: Name of customized distribution, if any (e.g., 'testpartner')<br/> |
| | DISTRIBUTION_VERSION: Version of the customized distribution (e.g., '1.0) |
| | </td></tr> |
| </table> | | </table> |
| </blockquote> | | </blockquote> |
|
| |
|
| Back to [[Software Update]] | | Back to [[Software Update]] |