Menu
Hacker News·September 2, 2026

Understanding Abstraction in System Design: Hide vs. Reduce

This article distinguishes between two critical types of abstraction in system design: 'modularity abstraction' (hiding implementation details through interfaces) and 'modeling abstraction' (reducing a system to its essential behaviors for analysis). Understanding this distinction is crucial for effective system design, especially in distributed systems where concurrency and invariants are paramount. The piece argues that while modularity focuses on ease of use and encapsulation, modeling abstraction explicitly exposes and leverages concurrency to prove system properties.

Read original on Hacker News

Two Forms of Abstraction in System Design

The article highlights a common confusion in understanding 'abstraction' within computer science and system design. It posits that there are two distinct types, often conflated, each serving a different purpose and requiring different skills. Recognizing this distinction is fundamental for engineers, particularly when dealing with complex, concurrent, and distributed systems.

1. Modularity Abstraction (Hide)

This is the traditional form taught in CS, akin to Abstract Data Types (ADTs), APIs, and layered architecture. Its primary goal is encapsulation and information hiding. By drawing boundaries, it abstracts away internal complexity, allowing users or other modules to interact through well-defined interfaces without needing to know the underlying implementation details. Examples include TCP hiding IP, file systems hiding disk mechanics, and SQL hiding query plans. This abstraction *aspires to hide concurrency* and present operations as atomic, making modules easier to use but potentially obscuring performance or concurrency opportunities.

2. Modeling Abstraction (Reduce)

In contrast, modeling abstraction, as used in formal methods and distributed systems design, aims to reduce a system to its minimal behavioral skeleton that preserves a specific property. It's about cutting away everything orthogonal to the essence of that property, focusing on *what* the system does rather than *how*. This type of abstraction is often cross-cutting, slicing the system along behavioral planes. Crucially, it exposes concurrency and fine-grained actions to prove that invariants hold despite interleavings, thereby enabling the harvesting of maximum safe concurrency.

  • Modularity Abstraction: Hides internals, encapsulates, draws vertical boundaries, makes modules easy to use.
  • Modeling Abstraction: Reduces to minimal behavior, exposes concurrency, is cross-cutting, proves invariants.
💡

System Design Implication

When designing a distributed system, both forms of abstraction are valuable. Modularity abstraction helps organize the codebase and define clear service boundaries, improving maintainability. Modeling abstraction, often used during the design phase with tools like TLA+, is critical for reasoning about complex distributed behaviors, consistency, and fault tolerance before implementation, ensuring correctness and identifying optimal concurrency.

abstractionsystem design principlesmodularitymodelingconcurrencydistributed systemsformal methodsTLA+

Comments

Loading comments...