AlgoViz

Abstractions in system design

easy 22 min

An abstraction hides how something works behind a small, stable interface, so callers only need to know what it does.

Where it shows up

The same pattern appears across everyday software.

  • File systems

    Programs open a path and read bytes. Whether the bytes sit on an SSD, a network disk or in memory is hidden, until a slow network disk shows through as a slow read.

  • TCP

    It offers a reliable, ordered stream over a network that loses and reorders packets. A cut cable still leaks through as a timeout.

  • SQL databases

    A query says what rows you want. The planner chooses how. Two queries with the same result can differ greatly in speed, which is a leak you handle with indexes.

  • Object storage

    You put and get an object by key. Copies, disks and repairs are hidden behind that interface.

  • Operating system drivers

    Programs print or draw through one interface, and drivers translate it for each device.

  • Managed cloud databases

    Backups, patching and failover are hidden. The short reconnect during a failover is not.