Software Update:Checking For Updates

From MozillaWiki
Jump to: navigation, search

Back to Software Update

The Update Service:

  • checks for updates to the application on a background timer
  • provides a means for the user to check for updates to the application
  • provide a set of controls for determining update behavior

The Background Timer

The system will automatically check for updates without user intervention:

  • every 24 hours
  • on the first startup following an update, to check to see if the patch applied is the newest possible update or if there are newer ones.

Regarding critical security updates, it would be useful to the user, if we could display a pop-up or similar sort (like what we have for-- " New updates available ") with the importance of this critical security update. This way we can inform the user the urgent need for the upgrade.

The Update Check

  1. generate update service URL
  2. determine if updates are available
  3. determine action
  4. download patches
  5. verify patches
  6. install patches

Update Service URL

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 version
  • app buildid (for distinguishing between nightlies on a "tester" build stream for example)
  • app buildtarget
  • app locale
  • aus channel
  • distribution name
  • distribution version



See app.update.url below for the template used in creating the Service URL.

The Updates File

See Software_Update:updates.xml_Format for documentation of this format.

Preference Controls and State

  • app.update.enabled
trueEnables background update checking
falseDisables background update checking
  • app.update.mode
0 automatically download updates for minor and major updates, regardless of incompatibilities that may arise with addons
1 automatically download updates for minor and major releases, if no incompatibilities with addons are present, otherwise prompt
2 automatically download updates for minor releases, prompt about major releases
3 prompt about minor and major releases
  • app.update.interval
86400seconds between update checks
  • app.update.timer
5000milliseconds between app.update.interval expiry checks
  • app.update.silent
trueall update prompting should be suppressed
falseshow prompts to the user when there are events they should respond to
  • app.update.lastUpdateDate.background-update-timer
1114648397seconds since epoch of last update time
  • app.update.url
'3' is the schema version

PRODUCT: App name (e.g., 'Firefox')
VERSION: App version (e.g. '3.0a8pre')
BUILD_ID: Build ID (e.g., '2007083015')
BUILD_TARGET: Build target (e.g., 'Darwin_x86-gcc3')
LOCALE: App locale (e.g., 'en-US')
CHANNEL: AUS channel (e.g., 'default')
OS_VERSION: Operating System version (e.g., 'Darwin%208.10.1')
DISTRIBUTION: Name of customized distribution, if any (e.g., 'testpartner')
DISTRIBUTION_VERSION: Version of the customized distribution (e.g., '1.0)

Back to Software Update