liveBook · Manning

Backward compatibility

As explained in Machine Learning System Design

The ability of new software or an interface version to support existing code or clients without changes.

Backward compatibility keeps existing API clients working while a system evolves. A seemingly helpful change can become a lasting constraint: once a classification endpoint exposed a list of labels, removing it would have broken clients, even though users needed only one label. section 13.1

Protect compatibility by:

  • Designing a small external API over a more flexible internal API; internal changes then remain possible without breaking users. section 13.1.1
  • Separating machine-learning logic from input/output handling so components can evolve, scale, and roll out independently. section 13.1.1
  • Planning exposed fields and outputs carefully, because an unnecessary response shape can be difficult to remove later. section 13.1
  • Using client libraries, feature toggles, and simultaneous component versions to make changes safer for consumers. section 13.1.1 section 13.1
Figure 13.2 Layered API structure is simpler to maintain, test, and develop.
figure

Use the layered API diagram to distinguish the stable external contract from the changeable internal implementation. section 13.1.1

How Machine Learning System Design covers it

How deep it goes
Explains compatibility through exposed outputs, layered APIs, and model versions, but stops short of a migration procedure.
Examples
Uses a classification endpoint that exposed a one-item label list and a layered API structure.
What it assumes
Assumes API design and machine-learning service context while teaching compatibility through a concrete endpoint failure.
What you can do after
Apply it via stable external contracts, flexible internal implementations, and controlled component evolution.
How it connects
Connects API design with idempotence, feature toggles, A/B testing, and gradual rollout.

Also explained in

Compare how 18 books explain backward compatibility →

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Machine Learning System Design. The section links point to the parts of the book it draws on.