practice

Partial Deployment Verification

also called Artefact Completeness Check, Fleet Convergence Verification

Machine confirmation that every target in a fleet is running the intended artefact, independently checked, so that an incomplete rollout cannot present itself as a finished one.

knight capitaldeploymentsegregation of dutiesdead code2012

On 27 July 2012 a Knight Capital technician deployed new order-routing code to seven of eight production servers. The eighth kept older code. A flag that had previously driven retired logic was reused for a new purpose, and on 1 August the eighth server responded to it by running that retired logic. The firm booked a pre-tax loss of about $440 million in roughly 45 minutes. The SEC's order records that there were no written deployment procedures and no peer review of deployments.

The defect was not a bad change. It was an incomplete one — and completeness is the most machine-checkable property in the whole of deployment.

Why it matters

Incomplete rollout is a failure mode with no error message. Every server the deployment reached is healthy; the one it missed is healthy too, running old code that has been fine for years. Nothing in the system is in a state that any health check would call wrong.

It is also the failure that human verification is worst at. The person who ran the deployment remembers intending to reach every host, which is why the segregation-of-duties element here is not about malice: it is that the actor is the worst-placed observer of their own completeness.

Implementation patterns

  • The deployment system reports the artefact identity running on every target — a content hash, not a version label — and fails the deployment if any target diverges. Version labels can be applied to different builds; hashes cannot.
  • Independent confirmation of that report by a second person or an automated gate that the deployer cannot approve. The confirmation is of the verification, not a repeat of the deployment.
  • A standing convergence check, not only a post-deployment one, so a host that is rebuilt from an old image or restored from a snapshot is detected.
  • Remove dead code as a control rather than as housekeeping. Unreachable code is untested, unreviewed and unremembered, and the usual mechanism that revives it is the reuse of a flag, field or configuration key.
  • Never reuse an identifier that once meant something else. New meaning, new name — a rule that costs nothing and removes the specific mechanism above.

Industry example

The 2012 incident is the canonical case because the SEC's account is detailed and public, and because the two contributing decisions are so ordinary: dead code left in place, and a flag repurposed. Modern deployment tooling has largely absorbed the lesson — declarative orchestrators reconcile continuously and report per-target artefact state by default — which is why this failure now appears mostly in systems deployed by scripts, in appliances, and in edge fleets where convergence is not continuous.

Failure scenarios

  • A host offline during deployment, rejoining later with old code and no alert.
  • A host rebuilt from a stale image, reintroducing a version that was rolled out past months ago.
  • Version labels rather than hashes, so two different builds share a tag and the check passes while the fleet diverges.
  • Dead code reached again by a reused flag, which is the specific 2012 mechanism and remains common wherever configuration keys are recycled.
  • Verification performed by the deployer, who confirms what they remember doing.

Trade-offs

The check is cheap where tooling provides it and genuinely awkward where it does not — edge devices that are intermittently connected, appliances with vendor-controlled update paths, fleets spanning networks that cannot all be queried. In those environments convergence becomes eventual, and the honest design states a convergence window and alerts when a target exceeds it rather than pretending the fleet is uniform.

Independent confirmation costs a second person's time on every deployment, which is why it is worth reserving for deployments whose loss rate justifies it rather than applying it universally.

When not to use it

The control should be proportional to loss rate per minute. A firm that can lose millions a minute needs machine-verified deployment and independent pre-trade limits. A team shipping an internal reporting tool needs neither, and adopting them because of this story is the wrong lesson.

What transfers everywhere is the completeness check itself, because it is nearly free and most deployment tooling now provides it by default. What does not transfer is the heavier apparatus — independent sign-off on every release, position limits, kill switches — which belongs to systems where an uncontrolled minute is catastrophic. Reading this case as an argument for more change approval is the common misreading: a review board would have approved the change, because the change was fine.

Interview question

Q: A deployment reaches seven of eight servers and nothing alerts. Tell me why no health check catches it, which control prevents it, and which controls only limit the damage.

What a strong answer covers: that every host is individually healthy so no health check has anything to report · artefact-identity verification by hash across all targets, failing the deployment on divergence · independent confirmation, and why it is about observer position rather than malice · standing convergence checks for rebuilt and restored hosts · dead code and identifier reuse as the enabling pair · staged rollout, kill switches and position limits as damage limitation rather than prevention · and proportioning the heavier controls to loss rate rather than adopting them wholesale.

Quick check

Quiz: Why does an incomplete deployment produce no alert? Because every host is healthy, including the one running old code, so no health check is in a position to notice the divergence.

Flashcard: Why verify by artefact hash rather than version label? Labels can be applied to different builds, so a label check can pass while the fleet is running two different things.