The interview problem
Design a platform that rolls out a new ranking model to a service handling 10,000 requests per second. The candidate needs a new feature version and changes score calibration. Detect operational and quality regressions, limit exposure and roll back without breaking downstream consumers.
Original ML design practice, not a reported company interview. All traffic, timing and failure rates are hypothetical. Primary technical source retrieved September 27, 2026.
1. Define the release as a compatible bundle
A model file is not the whole release. Pin weights, preprocessing, feature definitions, tokenizer when relevant, serving runtime, output contract and calibration or decision thresholds. Store an immutable release manifest with artifact hashes, evaluation evidence and compatible input/output versions. Promotion moves a traffic policy to a specific manifest, not to a mutable “latest” file.
Assume the existing model remains available during rollout. Version the new features alongside the old ones and validate both paths before switching traffic. A rollback that loads old weights against incompatible new features is not a working rollback. Similarly, downstream thresholds must consume the correct calibrated score version.
Ask which regressions require immediate abort, which require investigation and what evidence permits promotion. Request success and latency are operational signals; relevance, business outcomes and harmful outputs need separate evaluation. A service can return HTTP 200 while producing systematically worse rankings.
2. Separate serving from the rollout controller
Use an artifact registry and release catalog, a controller for promotion state, a version-aware router, separate candidate/control serving pools and a telemetry pipeline. The controller moves a release through validated, shadow, canary, expanding, promoted or rolled-back states. Persist transitions with actor, evidence, traffic policy revision and timestamps.
Routers consume immutable routing revisions and report their applied revision. An abort increments the revision and stops new candidate assignments; track convergence rather than assuming a global instantaneous switch. Define how in-flight requests finish or cancel. A stale controller must not overwrite an abort, so updates use conditional revision checks and fenced ownership.
Log assigned variant and actual executed bundle, including fallback, along with feature version and outcome correlation ID. Keep assignment-based quality analysis separate from execution-based service debugging. Excluding failed candidate executions would make a broken release appear healthier.
3. Learn from shadow traffic without changing outcomes
Shadowing sends a sampled copy of eligible inputs to the candidate while only the control answer reaches the user. Suppress candidate side effects and prevent its caches, counters or writes from changing the production workflow. Apply the same data-access and location constraints to shadow requests as live requests.
Compare feature availability, score distributions, ranking overlap and latency under a realistic load. A different ranking is a diagnostic signal, not automatically a regression. Shadow traffic cannot observe how users would respond to a ranking they never saw, so it does not establish the candidate's business impact.
At 10,000 live requests/s, a 5% shadow sample adds 500 candidate requests/s. If candidate compute per request is twice control compute, incremental inference work is roughly 10% of the original serving work under a linear-cost approximation. Shared feature reads, queueing and cache effects can make the true overhead different. Bound shadow work so it cannot starve live requests.
4. Use a canary with explicit evidence gates
Assign a small eligible cohort consistently at the user or other appropriate experimental unit. Maintain a contemporaneous control and monitor allocation balance. Request-level randomization can cause inconsistent experiences and correlated observations; choose the unit from the product behavior. Shared inventory or social interactions may require a different experimental design.
Start with operational gates: feature errors, timeouts, crash rate, saturation and output-schema validation. Then evaluate quality against a prespecified metric and guardrails, with enough exposure and label maturity for the intended decision. A ten-minute healthy canary is not a week-long retention experiment.
For a canary receiving 1% of requests, expected candidate traffic is 100 requests/s. A cohort containing 1% of users need not produce 1% of requests; measure its actual traffic share. If control errors are 0.1% and candidate errors are 2%, candidate excess is 1.9 errors/s. Across the entire service that adds only 0.019 percentage points, producing about 0.119% total error rate. Aggregate monitoring can hide a severe candidate-specific regression.
If detection plus routing convergence takes 90 seconds at these steady rates, about 171 excess errors occur. This is an expectation, not a maximum exposure guarantee. A hard request budget needs admission enforcement, including coordination across routers and in-flight work; a percentage flag alone cannot supply it.
5. Do not promote on absent evidence
Require both minimum observation conditions and acceptable results. If labels arrive after seven days, define an initial operational ramp with bounded exposure and a later quality decision. Proxy metrics can screen obvious problems, but document their limitations instead of calling them ground truth.
Check important language, device, customer and task slices with an analysis plan. Avoid repeated arbitrary significance checks or selecting only favorable metrics. Use an appropriate sequential method or a prespecified fixed-horizon analysis, and account for the planned family of claims. Scheduling several interim looks still requires a method that accounts for those looks. Report uncertainty and practical effect sizes; failure to detect harm is not proof that harm is absent.
Compare the full release bundle on a stable evaluation set before launch. If feature generation changes and model behavior changes simultaneously, the release may still be valid, but diagnosis is harder. Independent validation and staged compatibility changes reduce uncertainty without pretending every dependency can always be separated.
6. Rehearse rollback as an operation
Keep control capacity warm enough to accept returned traffic. If the candidate owns 50% of traffic and old capacity has been halved, moving the routing flag back can overload the old pool. Test restoration of capacity and feature compatibility before a large ramp, and keep the rollback budget in resource planning.
On abort, freeze promotion, publish the new route revision, verify applied versions and continue measuring errors until recovery is observed. Invalidate or namespace candidate-derived caches where necessary. Preserve release evidence for diagnosis. A rollback does not undo recommendations already shown, messages sent or external actions completed; those may require a separate remediation plan.
If the new release wrote a state format the old code cannot read, use a compatibility migration, a safe adapter or another tested recovery path. Do not advertise instant rollback when irreversible state changes have removed that option. Promotion should fail its readiness gate until the chosen fallback is concrete.
7. Defend failure cases and trade-offs
Shared feature infrastructure fails for both variants: compare absolute health as well as candidate/control differences. Candidate users are concentrated in one region: investigate allocation and representativeness before attributing a difference to the model. Labels disappear only for failed candidate calls: repair measurement and retain failed assignments. Rollout telemetry fails: hold promotion under the declared policy rather than interpreting missing alarms as success.
Foundation: distinguish shadowing from a user-facing experiment. Senior: calculate hidden canary errors and restore compatible features. Staff: reconcile delayed quality evidence with exposure budgets and irreversible downstream effects.
Score 0–2 each for release compatibility, traffic control, operational versus quality evidence, rollback readiness and failure analysis. Continue with artifact distribution and experiment assignment.
Sources and next steps
- Google SRE Workbook: Canarying Releases — partial rollouts, control comparisons and release evaluation.
The model-specific bundle, shadowing scenario, arithmetic and quality gates are original practice. The source is engineering guidance, not evidence of a recently asked Google interview question.
Continue your preparation
Choose a connected learning path or browse more ML system design questions. Read our editorial method and attribution policy.