There is one ridiculously inadequate metaphor of programming, as explained to non-programmers: Programming is just like snapping together some Lego blocks. This one must be familiar to everyone in the world today. It is inconceivable, but sometimes even executives in software companies believe in it. Anyways, a “new” metaphor was making rounds on the internet lately: the metaphor of software development like dealing with transplant organs. Euch.

It’s easy to see why this one is inadequate too. It implies that we know the function of the software that we’re “implanting”. As if nobody ever used software components not in the way its original author envisaged simply because they didn’t know it wasn’t its purpose. There wasn’t (thanks God) yet a surgeon implanting a heart and thinking it actually should function as a liver, but it’s totally normal to see a software developer using a queue as a persistence layer — or vice versa.

What’s even worse, organ transplant metaphor lacks a very important quality: it ignores the context of the world of which software system is inevitably only a small part. A heart is still a heart in 1987, 2007 and 2027. The same software module can either be immensely useful, or painfully useless, depending on the day and age it’s used in.

So I have a better metaphor. Or rather I have seen a better metaphor in the lectures of Alan Key: software components are like proteins in the living organism. Not cells, one level lower, proteins. Like software, proteins are complex, and we need several levels of abstraction to deal with them: both physics and chemistry, as well as physical chemistry and chemical physics need to be applied. Those abstractions are also “leaky”: things that are known in one of these disciplines are routinely not what they appear when considered in a context of another. Proteins interact with each other and their environment according to some grand plan only in an ideal isolated world, like the world of a biological cell. In short, there are several reasons to believe that this metaphor may be a useful one.

Does it help us writing better software? It does, but not in a direct way: it instead helps to see how primitive is what we’ve built so far, and how far we can go. If we’re making parallels with biology, our software is not even at the level of cells, leave alone tissues, organs, organ systems or organisms, and probably will not reach those levels if we stick to our current methods of software development. What’s the way to advance there? I don’t know and not sure anyone in our industry knows it yet.