Fennec Updates on Android
Fennec upgrade to the new releases will be handled automatically through Android Market, but a similar functionality is needed for Alpha/Beta versions and nightly builds.
Most of the information on this issue is collected in bug 587384 and related bugs.
The current approach is to use the same update service mechanism as for Firefox, just download and install a new .APK instead of .MAR patches.
The workflow is as follows:
- The background update service checks for the updates periodically. The interval is controlled by app.update.interval preference, which by default is 28800 seconds (8 hours);
- When update is available a notification is shown: "Get the new version..." (see bug 594238 for our new nsIUpdatePrompt implementation);
- When user confirms the update, it starts downloading;
- On download completion, another notification is shown: "Install the new version...";
- When it's clicked, Fennec restarts;
- On startup GeckoAppJava checks for a downloaded update.apk file, launches it, and writes the "succeeded" status to the update.status file (see bug bug 594897).