Fog Creek Software
Discussion Board




Patterns never took off?

On the book reviews page, Joel says about Alexander's "A Pattern Language", "I think the patterns movement in programming never quite took off because it was an attempt to copy the form of this book rather than the wisdom of this book."

I find this pronouncement a bit strange, because where I work, design patterns are ubiquitous. I can't move from the elevator to my desk without running into patterns.

A lot of the time, design patterns are misunderstood or misused (the idea is not to take a bunch of square pegs and shove them in round holes, it's just to recognise when the hole is square in the first place, and pick the right peg), but it's very difficult to avoid them.

Or am I just working in a weird corner of the industry?

Charles Miller
Wednesday, March 13, 2002

I'm working at the moment at a client that's keen on patterns to design things, partly because they get a lot of ups-and-downs in the workload. Hence they end up with contractors coming and going, and hence would like to feel that there's some chance of these contractors co-operating while seperated by time.

Which I think is an important thing to consider: while UML and a couple of other methodologies would solve the problem as well, patterns are a bit lighter-weight, and more overviewey for getting people up to speed on systems. If it's been written with patterns, someone who can talk patterns should have less trouble reading it.

Other places I've worked asked lots of interview questions about patterns, but when it came to the actual work, their code tended not to use "complicated" things like inheritence, templates, patterns, designs, specifications or any noticeable methodology at all.

A lot of them talk the talk and then seem to have trouble walking anything as advanced as const-correctness.

I don't think patterns have taken off, to be honest. Neither has proper C++ or generative programming. Lots of people USE the STL, but don't use that level of leverage in their own code. More and more I see two schools of developers: a class who are patiently working through things like patterns and generative, and a group who gave C++ a couple of years, but that bullet wasn't magic enough so they ran off and now are currently bailing from Java (because it's not magic enough) and betting C# will be magic enough to solve their problem. Not that patterns don't work in those languages, but there's a thought pattern in the industry that software development isn't hard because we're not thinking enough about it, but because we're using the wrong languages or tools or environments or something.

It takes years and years of work and a lot of experience to become a good writer in English, and only some people can do it. And you have to learn the forms of doing it - the patterns if you like: stories have shapes to them, that have been learned over centuries.

A lot of people in the software industry seem to be working to some sort of thought that you can bypass all of that: all that personal experience, personal talent AND using the gathered experience of others in other centuries isn't necessary. If they try German or French or Italian... surely in SOME language you can tell stories without needing all that...

That's what I think patterns represent; the gathered and bundled experience of others in an accessible format. Too many people in the software industry don't feel they have anything to learn from anyone else's experience and so they don't need to pay attention to them.

Katie Lucas
Wednesday, March 13, 2002

I tend to agree with Richard Gabriel's explanation as to why patterns never took off. His view was that design patterns were viewed by some as merely a way to address deficiencies in programming languages.

Alan Hecht
Wednesday, March 13, 2002

I recall reading an architecture book that claimed that pattern languages turned out to be a failure at helping create great buildings.  I think the argument is to the effect that writing beautiful sentences doth not a great novel make.

I think design patterns' success depends on where you stand.  If you've programmed in Java for a week, you couldn't have missed it.  It infects the API like a virus.

In the Microsoft world Joel inhabits, it's probably a curious fad that passed with no real legacy.  Politically, design patterns probably had no strong influence at Microsoft.

Speaking of politics, has anyone ever read The Decline and Fall of the American Programmer?  The design patterns crew followed the politics of building a capital-M Methodology to the very details.  Many books were released; evangelists raised high.  Methodologies, like programming languages, is big business, and the XP crew followed the well-known patterns in delivering it to the masses.

Decline & Fall now predicts (IIRC) that the XP movement is soon in the declining stages.  People are on to new things, and proponents need not be missionaries in the wilderness.  That's not a bad thing, since it often means it's been accepted into standard parlance like OOP.

american programmer
Wednesday, March 13, 2002


I have been slowly reading Alexander's "A Pattern Language" and it is vastly overhyped. There are some good ideas, but Alexander wanders a vague path between city planning and pop psychology. He is long-winded and high on himself. His "quality without a name" is pompous and self-congratulatory.

On the otherhand, I think the "Gang of Four" design patterns book is invaluable!! The most useful contribution of design patterns is that they provide a new vocabulary, to help software developers communicate more easily. These days, everyone uses phrases like "bridge", "singleton", and "factory".

Banana Fred
Wednesday, March 13, 2002

Patterns never took off??  This seems to be practially a contradiction in itself.

Design patterns give us a language to describe commonly used class groups/relationships/combinations in OO programming.  The very existance of design patterns is because these patterns were already in common use, therefore the actual patterns had already 'taken off'.

Look at any decent sized OO framework or library and you will see a number of design patterns at work.  Many people use patterns without even knowing it, they certainly did before the standard design pattern terminology was invented!

As a method of communication, it seems to me the language of design patterns is pretty well known for the most common patterns.  If I say, 'this class is a singleton' then most people in the OO world will know what I mean, simpler than saying 'It is only possible to instantiate one object of this class'.

Where patterns have not taken off is direct language support.  None of the mainstream languages have constructs which directly support patterns ie. there is no 'singleton' keyword in Java for example.  But given that the design pattern language has only been around for a few years, this isn't surprising.

Peter

PeterM
Wednesday, March 13, 2002

Two books that definietly should be on the list:

Design Patters (Gof4)

Refactroing (Martin FOwler)

THese have been done to death. But they are essential reads for programming.

Adam
Wednesday, March 13, 2002

I agree about both.  I'd also add "UML Distilled" by Fowler.  UML combined with patterns combined with refactoring is a powerful, powerful thing.  IMO, no one should call themselves a software architect these days without a solid foundation in all three.

Timothy Falconer
Wednesday, March 13, 2002

One way to think of patterns is as a step in the continuing chain of abstractions that started when we began writing code in assembler instead of machine language. I've had more to say about this at http://www.mcpmag.com/newsletter/article.asp?EditorialsID=68 .

Mike Gunderloy
Thursday, March 14, 2002

If I understand correctly, patterns are, whether we recognize them as such or not. "Taking off" or not isn't really the issue.

Sort of like the tree in the forest making a noise if nobody's there to hear it? (Or my favorite -- "if a man's alone in the forest without a woman and he says something, is the man still wrong?" Based on 18 years of happy marriage, I can say that the answer -- at least my wife's answer -- would be "of course he's still wrong!")

;-)

Anyway, it seems to me that the key issue is whether we can:
1) identify the patterns around us
2) identify their areas of applicability
3) identify, create, collect and package all the necessary supporting artifacts to enable us to take advantage of the patterns in real situations.

By this I mean identify or create the list of specific, implementable and testable behaviors associated with the pattern, by context in which it applies, any artifacts required to persist our understanding of the pattern, and any tests we need to verify that any implementation of the pattern has been done successfully.

Like I said, though, *If I understand this correctly*, which I may not.

F.J. Weiland
Thursday, March 14, 2002

I no longer know if we're discussing whether "patterns" are good (I'll weigh in on the "yes" side) or whether they took off (I'm not sure they did), or *why* they did not.

I loved the original Gamma et al book, and wish I had read it earlier so I would not have had to find some of these via the school of hard knocks.

If they did *not* take off, it's because there are still too many shops where managers want to see one thing from developers: hands on the keyboard, banging out code.  No thinking allowed, although there's heck to pay when the code breaks down. This is frequently the case in MIS shops where the managers are accustomed to running the mail room or something like that and have no idea how knowledge workers operate.

Fortunately, I've worked in shops that had an open mind about productivity issues. Not coincidentally, these are frequently managed by people who *have* been knowledge workers.

skautsch
Friday, March 15, 2002

It seems to me that Patterns DID take off, but only very narrowly. Specificly, everyone is using the original GoF patterns, but nobody is inventing any other really useful ones, at least not in the actual software development arena.

I did a quick web search, and only turned up a couple of pages that were not reviews of the GoF book, or pages explaining what patterns are, but not defining any new ones. There are a couple of 'Catalogs of Software Design Patterns', but most of them seem to have only the original GoF patterns or minor variants.

Is it possible that the GoF actually identified all the useful ones?

David Clayworth
Friday, March 22, 2002

> Is it possible that the GoF actually identified all the useful ones?

There's a series of at least 4 books called _Pattern Languages of Programming_, apparently the results/proceedings of an annual conference. The patterns in them are more mixed than the GoF ones, with domains ranging from user input validation, real-time software, how to organize staff into various roles, a dozen or so patterns per book. I think the GoF identified core ones.

Christopher Wells
Friday, March 22, 2002

*  Recent Topics

*  Fog Creek Home