Confirmed users
657
edits
(→Goals) |
No edit summary |
||
| Line 1: | Line 1: | ||
This page describes the technical plan to move the process of applying the updates in Firefox to the background as opposed to at startup. | This page describes the technical plan to move the process of applying the updates in Firefox to the background as opposed to at startup. In order to get a clear idea about the scope of the project, please see the Goals and Non-Goals sections below. | ||
= Goals = | = Goals = | ||
# Moving the update process to the background | |||
# Initiating the update process as soon as an update is downloaded | # Moving the update process to the background | ||
# Being able to apply a newer update if Firefox was not restarted since the previous update was applied in the background | # Initiating the update process as soon as an update is downloaded | ||
# Try to do as little as possible at startup | # Being able to apply a newer update if Firefox was not restarted since the previous update was applied in the background | ||
# Try to do as little as possible at startup | |||
# Eliminate the progress bar UI that the current updater shows | # Eliminate the progress bar UI that the current updater shows | ||
= Non-Goals = | = Non-Goals = | ||
# Handling UAC prompts on Windows | |||
# Changing the frequency of checking for updates, our handling of major/minor updates, or the way we check for add-ons compatibility | # Handling UAC prompts on Windows | ||
# Eliminating the UI we display in Step 2 | # Changing the frequency of checking for updates, our handling of major/minor updates, or the way we check for add-ons compatibility | ||
# Changing how updates work on Android | # Eliminating the UI we display in Step 2 | ||
# Changing how updates work on Android | |||
# Any of the other projects falling under the "silent update" umbrella | # Any of the other projects falling under the "silent update" umbrella | ||
= Implementation = | |||
Here is a proposal for how background updates will be implemented. | |||
* The process will start by Firefox checking for an update in the background (as it does today). | |||
* Once an update is found | |||
** If the user needs to prompted for some reason, we show that prompt. If the user declines, we bail out. | |||
** Otherwise, we go ahead and download the update (as a complete/partial MAR file) in the background. | |||
* Once the download is finished, Firefox launches the updater binary in the background with the UI display disabled. | |||
** The target of the update will be known <code>FIREFOX_NEW</code> from now on. | |||
*** On Windows, if Firefox is installed to "C:\path\to\Mozilla Firefox", <code>FIREFOX_NEW</code> will be "C:\path\to\Mozilla Firefox.new". | |||
*** On Mac, if Firefox is installed to "/path/to/Firefox.app", <code>FIREFOX_NEW</code> will be "/path/to/Firefox.app/Updated.app". In other words, the updated version of Firefox will be installed as a bundle inside the existing Firefox bundle. | |||
*** On Linux, if Firefox is installed to a flat directory like "/path/to/firefox", <code>FIREFOX_NEW</code> will be "/path/to/firefox.new". If it's installed in a non-flat directory structure (like /usr/bin for example), the details of where <code>FIREFOX_NEW</code> will be is TBD. | |||
** The manifest file will be known as a file named "update.pending" located in the root of the existing Firefox installation. | |||
* The updater binary checks to see if there is an existing manifest file. | |||
** If this file exists, it will be removed. | |||
* The updater binary checks to see if there is an existing <code>FIREFOX_NEW</code> directory. | |||
** If this directory exists, it will be removed. | |||
* The updater binary will go ahead and apply the update to the <code>FIREFOX_NEW</code> directory using the existing installation directory as the base. | |||
* The updater binary will write a new manifest file to the existing installation's directory. | |||