Rollouts and auto-pause
How a rollout percentage picks devices, how automatic progression raises it and how auto-pause stops a release when its failure rate crosses a threshold.
A rollout is the share of a release's audience that receives it, 0 to 100 percent, 100 by default. Auto-pause is the rule HotCodePush runs on every release: it pauses one whose failed updates exceed 5 percent of its applied updates. This page explains the mechanism, and Roll out gradually runs one step by step. The short version is the site's staged rollouts for mobile page.
The percentage and the bucket
Each device lands in a bucket from 0 to 99, a stable hash of its device id and the release id. It takes the release when its bucket is below the percentage. The bucket is the same on every check and different for every release.
So raising the percentage adds devices and never removes one, and lowering it stops new devices. A device that has the release keeps it whatever the percentage does.
The percentage applies among the devices the release's conditions reach. A device outside the bucket skips the release and reports it once, and the console shows the count per release. The audience preview in Target devices with attributes estimates how many devices a percentage reaches before the release exists.
A release at 100 percent supersedes a rollout for everyone. A newer release with its own rollout supersedes it for the devices in its bucket, and the older release stays for the rest. The console warns when a release is created while a rollout is in progress.
Progression
A release created with release create --progression carries a schedule. By default it widens through 10, 50 and 100 percent. Each step must hold at least 50 applied updates and at least one hour before the next.
HotCodePush widens the rollout to the next step once the step's sample and time are met and the failure rate stays below the threshold. It stops widening the moment the pause rule would fire. The console and release get show the step reached and what the next one waits on.
A rollout set by hand ends the schedule, and a resume after a pause restarts the current step. A progression needs a sample. Start at 10 percent with --progression once a channel holds about 1,000 active devices, so the first step's 50 applied updates arrive in reasonable time.
Auto-pause
Every device reports the outcome of an update. It reports applied when it launched the release for the first time, confirmed when the readiness gate passed, and failed with a reason when it did not. HotCodePush counts them per release, one per device, and evaluates the rule as reports arrive.
| Setting | Default | Meaning |
|---|---|---|
| Threshold | 5 percent | Divides the failed updates by the applied updates. |
| Minimum updates | 50 applied updates | Holds the rule back until that many updates applied, so one crashing test device cannot pause production. |
| Confidence | 95 percent | Lets the rule fire only when the rate is above the threshold with that confidence, so noise near it does not. |
| Window | since the release went live, or since its last resume | Judges a resumed release on new evidence. |
| Action | pause, and a notification | Says what happens when the rule fires. |
The action is one of four:
| Action | What happens |
|---|---|
pause | The release stops being offered, and devices running it keep it. |
revoke | Devices running it also move to the newest eligible release below it, or to the embedded bundle. |
notify | A notification goes out, once, and nothing else happens. |
none | The counters are kept and nothing happens, but a progression still stops widening. |
The policy is set per channel, inherited by its releases and overridable per release. revoke and none are opt-in. The notification, an email and a webhook event, carries the counters and the top failure reasons, and the pause lands in the audit log. The devices that failed have already recovered on their own. The rule protects the ones that have not updated yet.
Pausing and resuming
A paused release, by hand or by auto-pause, is offered to no one. A device that has it keeps it, and a device that does not takes the newest eligible release below it. A downloaded copy not yet applied is discarded.
Resuming offers it again and opens a new measurement window. Pausing the whole channel instead stops every release in it. Each action applies within about a minute, as How an update reaches a device describes.
Last updated on