Home > Programming > The Modern Programming Craftsmanship

The Modern Programming Craftsmanship

To make a start on the topic indirectly, I will state that one can view any kind of activity from different sides as different processes. Actually, there are different sides in any activity, but usually these sides are defined by people themselves. Chess, for example, were said to be an art by Wilhelm Steinitz, Emanuel Lasker considered them to be sport, Chigorin thought about chess as about science. But chess didn’t change because of these points of view, it’s the player who chooses the point for his own game of chess.
Today we see that the software engineering transformed from being a magic thing into the kind of craftsmanship. Programming is no more considered a fun delightful action but a slow tedious process of typing in tons of code, testing, debugging and repeating the cycle again. How did it happen? The whole IT sphere was from the beginning some kind of wizardry. A small amount of people made the large lifeless machines work and perform complex operations that were impossible to do for a human. But time has passed and wizards are now replaced with lots of commoners with minimal (usually insufficient) knowledge about the profession itself. This fact is much more mysterious and astounding to be left unquestioned.
To make it simple, lets draw the parallel to the woodcutting process. A thousand years ago there was a profession for it, and in order to make something of wood you had to ask a woodcutter – a person who specialized in that. But today we don’t need a woodcutter as a profession. Now the process of woodcutting is declarative – a professional of higher abstraction level defines a piece of wood he wants to have (in some kind of modeling software) and the machine does the rest. Perhaps, it needs some humans here and there (e.g. to carry the sample from one machine to another) but this can also be excluded soon.
Why is there still such a buffer as human in software engineering? Why a higher-level specialist, a software architect or the person who specializes in the domain directly, cannot declaratively define what kind of software he wants? Why should he depend on a bunch of monkeys (developers) and a bit smaller bunch of inspectors (project managers)?
There is more into it, that we can see at a glance. Software architect not only needs this buffer between him and a machine, but he has to know different things that these monkeys use. OOD, refactoring, TDD, various frameworks – a large amount of methods that don’t eliminate the human buffer but instead makes it useless though unavoidable. He (SA) doesn’t study computer science anymore, he learns the above-mentioned techniques to be able to communicate with the buffer. What a terrible waste of intellect.
One may say it is about business. That business doesn’t need ten almighty hackers but a hundred expendable and replaceable coders. That’s incorrect. Business needs fast, robust and cheap solutions and it’s better for business not to have people at all. Machines are better in any way – they can work 24/7 without vacations, don’t require insurance policies, are predictable and easily controlled. Each industry prefers machines to humans, but software development does not. And it won’t until everybody realizes the problem about that.
After all, what can we do to avoid this? The answer is simple and already known for a fifty years. The usage of DSL (Domain Specific Language) approach raises the level of abstraction by any height and lets a specialist of any sphere to operate the concepts and methods he used to. One pure example of this approach is SQL – a fine-grained DSL of its time. Another example is Wolfram Mathematica, the best computational software existing today. It was written in Mathematica language that was specially created for it.

Of course, you cannot so easily jump into writing DSLs and DSLs in DSLs and so on. This requires a host language capable of easy metaprogramming. Most of such languages are the Lisp derivatives that may ring you a bell. The mainstream languages come and go – ten years before the software companies were flooded with C++ coders, five years ago they all were replaced by Java/Python ones, now it seems like C# is the new cycle runner. But Lisp remains popular and useful for half a century now in any of its variations.

Code that writes code is a key. That is the natural way of development and not a rocket science as it is thought to be. Machines that build machines led to the scientific and technical revolution. Further research in the code-writing code industry can set up another one. Learn it, use it and you’ll see that programming is more magical than you ever thought.

If you want to learn more about metaprogramming and DSLs, you can start off with reading this article.

Answer to the comment about “No silver bullet”: the metaprogramming implicitly states that there is no silver bullet. It provides an ability to write the language for the problem itself, hence eliminating the “silver bullet” principle. You can create a bullet for your very task and it would be better than any existing all-purpose languages.

Advertisements
  1. November 12, 2010 at 9:01 pm

    There is no silver bullet. Frederick Brooks

    • November 14, 2010 at 3:23 pm

      Brooks is respected man indeed, but he addresses the wrong point. If you don’t see something working perfectly for now it doesn’t mean that it wouldn’t do at all. The fields of automated programming are not yet fully researched to be said to be wasteful. And there are not researched just because they were given up ahead of time. Business turned to monkeys because they provide the here and now result though poor, fair and pitiful.
      Check out this little example that monkeys may not be necessary anymore. http://www.genetic-programming.com/humancompetitive.html

  1. No trackbacks yet.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: