Case studies1 min read

Parcelwick moved 2,000 homegrown flags in one weekend

Parcelwick had 2,000 flags in a homegrown YAML service and nobody willing to touch it. They moved every one in a weekend, without a single user noticing.

Mara Sato

Mara Sato

Developer Advocate ·

Case studies cover: Parcelwick moved 2,000 homegrown flags in one weekend

Parcelwick routes a quarter of a million deliveries a day. Their flags lived in a YAML file served by a small internal service that had outlived three teams and its original author.

Everyone was afraid of the flag service, so nobody removed flags, so it got scarier. — Theo Lindqvist, Staff Engineer

The plan

  • Import every flag with its current value, untouched.
  • Run both systems side by side and compare every evaluation.
  • Switch reads over one service at a time, behind a flag (of course).
terminalShell
// What an edge node receives: a diff against the version it holds.
interface RulesetDiff {
    version: number
    previous: number
    changed: Record<string, FlagRules>
    removed: string[]
}

function apply(diff: RulesetDiff) {
    if (diff.previous !== store.version) return resync() // missed one: fetch a snapshot
    store.merge(diff.changed, diff.removed)
    store.version = diff.version
}

Shadow evaluation

For a week, every request asked both systems and logged any disagreement. There were eleven, all from one hand-edited YAML anchor. Fixed on Thursday, cut over on Saturday.

The result

  • 2,014 flags migrated, 312 of them deleted in the first month
  • 0 customer-visible incidents during the move
  • 1 internal service decommissioned, with some ceremony
Case studyMigrationLogistics
Mara Sato

Written by

Mara Sato

Developer Advocate

Mara writes the guides and talks to the teams who use Driftwire every day, then writes those conversations down as case studies.

More posts by Mara Sato