advanced
Migration strategy
Plan incremental migration with strangler steps, compatibility adapters, data backfills, dual writes only when controlled, and rollback points.
Large rewrites fail when big-bang cutovers meet production reality. Incremental migration uses strangler steps, compatibility adapters, controlled dual writes, backfills, and explicit rollback points. Each step should deliver user-visible value or measurable risk reduction.
Trade-off: dual running increases complexity temporarily but bounds blast radius compared to a single switch.
On interviews: design a migration from monolith to services for one capability — routing, data ownership, and how you verify correctness.
Common pitfalls: unbounded dual writes without reconciliation; no feature parity metrics; deleting the old path before consumers migrate.
Checklist:
- Slice migration by business capability, not layer.
- Define compatibility contracts and verification tests.
- Plan backfill, reconciliation, and rollback per step.
- Retire legacy only with traffic and data proof.