Things Have History
Design Patterns: the catalog that gave software a common language

software-architecture

Design Patterns: the catalog that gave software a common language

Listen · 4:08

In August 1993, a small group of programmers rented a mountain cabin in Colorado. Grady Booch had organized it. Kent Beck and Ward Cunningham showed up, along with Ralph Johnson, Jim Coplien, and a handful of others who were, in the argot of the era, serious about objects. Among the things they discussed was an idea borrowed wholesale from a British-American architect named Christopher Alexander — the notion that design problems come in recurring shapes, and that naming those shapes is half the battle.

One year later, the idea had a book.

Design Patterns: Elements of Reusable Object-Oriented Software appeared on October 21, 1994, published by Addison-Wesley with a foreword by Grady Booch. Erich Gamma had been developing the concept since his doctoral work at the University of Zurich; he and Helm met at the 1990 OOPSLA conference, at a session called “Towards an Architecture Handbook.” Ralph Johnson and John Vlissides were circling the same problems independently. The Colorado cabin was where the four finally converged.

The book catalogued 23 patterns sorted into three families: creational (how you build objects), structural (how you compose them), and behavioral (how they talk to each other). Factory Method, Observer, Decorator, Singleton, Strategy — names that would become a shared vocabulary for a profession that had previously improvised in silence. The examples ran in C++ and Smalltalk. Java hadn’t been released yet.

The intellectual ancestor of all this was not a programmer. Christopher Alexander was an architect who, in 1977, published A Pattern Language: Towns, Buildings, Construction, cataloguing 253 solutions to problems of built space — the geometry of a good entrance, the right scale for a neighborhood. He believed that recurring design problems had structural answers, and that writing them down was how a craft became a discipline. In 1987, Kent Beck and Ward Cunningham stood up at an OOPSLA conference in Orlando and asked whether you could do the same for software. The Gamma book was the answer to their question, arrived seven years and several mountain cabins later.

The four authors acquired a nickname: the Gang of Four, borrowed deliberately from the four Chinese Communist Party leaders convicted of Cultural Revolution crimes after Mao’s death. Whether this was meant as flattery or gentle mockery depends on your politics and your feelings about Singleton. In 2009, Gamma said publicly that if he were rewriting the book, he would cut Singleton outright — it had become so widely misapplied that he considered it a mistake worth un-naming. The other three disagreed. The Singleton survives.

What the book actually delivered was harder to quantify than its 23 patterns. It gave programmers a vocabulary. Before 1994, a developer who wanted to explain an Observer relationship needed a whiteboard and twenty minutes. After 1994, they needed one word. That shared vocabulary let complex systems get designed in conversation, across time zones and organizations, by people who had never met. Every major framework of the following two decades — Spring, JUnit, Ruby on Rails, Angular — was built from GoF components the way a house is built from standard joints.

More than 500,000 copies have sold in 14 languages. The examples ran in C++ and Smalltalk. The ideas ran on longer.

Sources

Spot a mistake?

Wrong date, broken citation, a fact that doesn't hold? Tell us. It lands in an inbox a human reads and the post can be pulled or corrected.