skip to content

In a music-streaming app, how should launch time be measured from real installs, and how does that number become a budget that blocks a regressing release?

level: seniorimportance: should knowfreq 48%

answer

  1. one lab phone is an anecdote
  2. split by start type and device class
  3. first frame and usable, both
  4. percentiles, release over release
  5. a regression fails the release

basics

~20 s

Record each launch's start type, entry point, device class, first-frame and usable-content times from real installs; report percentiles per release and segment; fail the release when a segment exceeds its budget or regresses past a set margin.

solid answer

~50 s

A lab phone tells you about one device in one state; the budget comes from **real installs**. For each launch record the start type (cold, warm, hot or resume), the entry point (icon, notification, lock-screen control), a device class, whether it is the first launch after an update, and two marks: the **first frame**, which the OS can time, and **usable content**, which only the app can mark. Report the 50th and 90th percentiles per segment and per release, never a blended mean, because a shift toward hot starts can lower a blend while cold starts get slower. Set each segment's budget from today's values, then gate: a lab run on a pinned low-end device catches big regressions before merge, and field percentiles from the first days of a staged release confirm or fail it. A release that breaks a segment's budget is fixed before it reaches everyone.

code

json · 11 lines
json
{
  "launch_id": "0b6f2c4e-8a1d-4f3b-9c2e-5d7a1e3f9b20",
  "app_version": "8.14.0",
  "start_type": "cold",
  "entry_point": "notification",
  "device_class": "low",
  "first_launch_after_update": false,
  "first_frame_ms": 1180,
  "usable_ms": 1960,
  "outcome": "usable"
}

go deeper

for a junior

Recall that launch time is measured from real installs, not one lab phone, and that it has two marks: the first frame and the moment content is usable.

for a middle

Explain the segments (start type, entry point, device class, first launch after update) and why percentiles beat means for a launch metric.

for a senior

Show the gate: per-segment budgets from field data, a regression margin with a minimum sample, a lab early warning, field confirmation in a staged release, and the traps of mix shift and survivorship.

for a principal

Frame the budget as a contract across teams: who owns each segment's number, how a breach is attributed to the work that grew, and when the budget itself is renegotiated.

## Why a lab phone is not the number A launch measured on the team's test phone is one device, one storage state, one network, usually a recent flagship. Real launches spread across years-old phones, nearly full storage, other apps competing for memory, and every network. One platform's guidance describes cold and warm launches as a **spectrum** that depends on the device's state, which is why testing in a variety of conditions is needed to predict real-world performance. So the budget is set on **field data**: launch timings collected from real installs, segmented, and read as percentiles. Lab runs still matter, as an early warning before merge, but they are not the verdict. ## What to record per launch | Field | Why it is needed | |---|---| | Start type | cold, warm and hot starts do different work and must not be pooled | | Entry point | icon, notification and lock-screen launches may build different first screens | | Device class | a coarse tier (for example low, mid, high) set by the team; low-end phones show regressions first | | App version | to compare release over release | | First launch after install or update | those launches can be slower for reasons unrelated to the code change | | First-frame time | the OS can time this on both platforms | | Usable-content time | only the app knows when the resumed track and playlists are usable, so it marks this itself | | Outcome | reached usable content, or abandoned first, with the time it lasted | The last row matters more than it looks. A user who gives up before content appears never produces a usable-content time. If those launches are simply dropped, the slowest launches vanish from the data precisely when they get worse. Record abandonment as an outcome and watch its rate. Getting these records to the server (buffering, batching, retrying) is the job of the analytics pipeline; this design decides what they mean. ## Turning samples into a budget 1. **Segment** by start type, device class and entry point; keep first-launch-after-update separate. 2. **Use percentiles, not means.** The median shows the typical launch; the 90th percentile shows the slow tail that users complain about. One platform's developer tools already present launch times at exactly these two percentiles, by device. A mean hides the tail, and a blend across start types hides cold starts behind hot ones. 3. **Set a budget per segment.** Start from today's field values, not from a number found online; the truth is your own fleet. For example, as this scenario's **assumption**: cold start on the low-end class, first frame at the 90th percentile within 2.0 s, usable content within 3.0 s. 4. **Define a regression.** For example, as an **assumption**: more than 10% above the previous release at the same percentile, in a segment with at least 1,000 launches, so that small segments do not trip it on noise. ## Where the gate sits - **Before merge or release candidate**: a lab run of a scripted cold start on a pinned low-end device, repeated enough times to see past noise. It catches large regressions cheaply but cannot see the field's variety. - **In the first days of a staged release**: field percentiles for the new version, compared with the previous version on the same segments. A breach is a release blocker: the regression is fixed or the offending work removed before the release reaches everyone. When and how the rollout itself is halted is the release design's decision; the budget supplies the signal. - **Ownership**: a breach names the work that grew, using the per-phase timings the start-up registry records, so the owning team fixes it. ## Traps that fake a good number - **Mix shift.** A release that keeps processes alive longer produces more hot starts; the blended median falls while cold starts slow down. - **Moving work past the first frame.** The first-frame percentile improves while usable content worsens; budget both. - **First launches after an update.** In the first days of a rollout these are over-represented and can be slower; compare like with like. - **Survivorship.** Dropping abandoned launches flatters the tail. - **Too few samples.** Percentiles in a tiny segment swing between releases; set a minimum count before the gate fires.

  • The median cold start improved this release, yet users say launches feel slower; how can both be true?
    Look at the tail and the second finish line. The median can fall while the 90th percentile on low-end phones rises, and a change that moved work past the first frame improves first-frame time while usable content gets later. Read each segment's percentiles for both marks before believing the headline.
  • Why not gate releases on the lab benchmark alone?
    A lab run sees one device in one state on one network, so it catches large regressions but misses those that only appear on old phones, full storage or weak signals. Use it as a cheap early warning before release, and let field percentiles from the first days of the staged release decide.

  • The average launch time across all users is the number to budget.
  • A launch timed on the team's flagship phone represents the user base.
  • Time to the first frame alone shows when the app is usable.
  • Cold, warm and hot starts can be pooled into one launch metric.
  • Launches abandoned before content appears can simply be dropped from the data.