• Housekeeping 16.05.2007

    I just read the latest article by Joel Spolsky over on Joel on Software (a site you really should bookmark). Joel reminisces about the time he had his First BillG Interview where he had to present the spec for what was going to be Visual Basic for Applications to Bill Gates. It’s a good read, hospital visit web and Joel’s writing style is very entertaining. While Joel and I have differing opinions on some things, I certainly respect his experience and knowledge, and I suspect that the things we disagree about are simply related to the fact that he takes some concepts too literally (especially with regards to such Agile concepts and no BDUF, but’s that’s for another post).

    Towards the end of the post, Joel makes this observation:

    Bill Gates was amazingly technical. He understood Variants, and COM objects, and IDispatch and why Automation is different than vtables and why this might lead to dual interfaces. He worried about date functions. He didn’t meddle in software if he trusted the people who were working on it, but you couldn’t bullshit him for a minute because he was a programmer. A real, actual, programmer.

    Watching non-programmers trying to run software companies is like watching someone who doesn’t know how to surf trying to surf.

    "It’s ok! I have great advisors standing on the shore telling me what to do!" they say, and then fall off the board, again and again. The standard cry of the MBA who believes that management is a generic function. Is Ballmer going to be another John Sculley, who nearly drove Apple into extinction because the board of directors thought that selling Pepsi was good preparation for running a computer company? The cult of the MBA likes to believe that you can run organizations that do things that you don’t understand.

    Hear! Hear!

    You know, it’s not that I don’t respect management as a discrete set of skills, a seperate discipline if you will. Managing anything successfully requires a particular mindset and approach that is quite specific to the task of management, and the actions that a manager does (and the skill required to carry them out effectively) are specific and distinct from those needed in other endeavours (like, oh, I don’t know… developing software, for example).

    That does not mean, however, that those skills are all that a manager needs in order to be effective.

    I guess it is theoretically a possibility that somewhere there is an activity that can be managed by someone who has no understanding about that activity. (I am not saying that there is such an activity, just that there might be.)

    But developing software is not it.

    It is simply not possible to manage a software development business without a reasonable understanding of software development. I am not going to try to justify that statement here, because quite frankly either you know that this is true, or you can’t possibly be convinced that it is. What I will say, after 28 years in this game, is that whenever I have had to work with a "manager" that does not understand software development, the end result has invariably been sub-optimal. And by "sub-optimal" I mean a disaster, except where this was avoided by those who did understand and who went far beyond what could be expected of them and worked around that manager to get things done.

    While it is not necessary (indeed, it may not even be desirable) for a manager in a software business to be the most technically competent developer, it is an absolute requirement that he or she be able to understand if something is easy or hard, if it is high risk or low risk, if it is reasonable or unreasonable, if it is obviously wrong, obviously right, or just plain not known. He or she needs to understand whether an estimate is reasonable, or whether it is too optimistic or too conservative.

    If the manager can’t do these things, then how can he or she manage? Can you imagine this scenario? If I were asked to manage a banana farm (an activity I know absolutely nothing about) then here is a conversation with the farm workers:

    Me: The buyers want bananas that are more uniform in size. How can we do this?

    Workers: You can’t. Bananas have a certain variation in size. Indeed, the particular species we grow is internationally recognised as the most uniform in size.

    OK. Now what? Is this true? What do I do next?

    Worse still, the previous day, in the meeting with the buyer, the conversation had gone like this:

    Buyer: Our consumers are complaining about the variation in the size of the bananas. We need them to be far more uniform.

    Me: Oh, I’m sure that is not going to be a problem. After all, we employ world best practice farming techniques. I am sure we can do something about that. So if we add a clause to that effect into the contract, you will sign an order today?

    Buyer: Yes, but only if you can assure me you can have a smaller variation in the size.

    Me: No problem. Sign here, please.

    If this sounds ridiculous to you, welcome to my world…

    I don’t remember quite how long ago I first read this book, this web but today I just had to go and pull it off the shelf in my office at work, dosage where it normally lives. Very near to the front, there it tells of one study where the authors took two pieces of corporate writing, one in typical corporate-speak, and one straight-talking and clear. The identities of the companies was not evident or otherwise discernable from the content.

    They took these two pieces and showed them to a number of people in the local (to them, Atlanta) Starbucks, and asked them to select from a list of 30 words the ones that they would associate with the companies involved. There were 15 "positive" and 15 "negative" words in the list. Interestingly, the Starbucks crowd didn’t like the bull, so the four words most strongly associated with the writer of the corporate-speak were obnoxious, rude, stubborn and unreliable. And none of the 15 "good" words were associated with this company’s literature.

    The other piece fared much better — it was associated with the words: likable, energetic, friendly, inspiring and enthusiastic. None of the "negative" words were assoaciated with it.

    Let me quote from the book:

    The short story is that people find straight talkers likable, and that’s a big deal. In his book ”The Power of Persuasion”, Robert Levine, a professor of psychology, says:

    If you could master just one element of personal communication that is more powerful than anything … it is the quality of being likable. I call it the magic bullet, because if your audience likes you, they’ll forgive just about everything else you might do wrong. If they don’t like you, you can hit every rule right on target and it doesn’t matter.

    The authors also note that two if the words that were included in the list were "intelligent" and "educated". There was no statistical difference between the straight-talk sample and the bull sample. This means that an attempt to appear smart by (as they put it) using fifty-cent words to make 5-cent points, is pointless — there is simply no payoff for the verbosity.

    Quoting again:

    The bottom line: Bullshit eats away at your personal capital, while straight talk pays dividends. Invest wisely.

    Amen to that!

    Today I have endured more double-speak and, well, absolute nonsense than anyone should ever need to be exposed to, because of some fear of being absolutely clear in some communications. A futile attempt at stealth management.

    I’ll feel better soon.

    Really I will.

    My daughter forwarded me an email just today, neurosurgeon to which she had simply added a single line at the beginning. She said:

    I LOVE YOU DAD !!!

    And here is the rest of the email, which she had obviously forwarded from one of her friends who had sent it to her:

    When you were 8 years old, your dad handed you an ice cream.
    You thanked him by dripping it all over your lap.

    When you were 9 years old, he paid for piano lessons.
    You thanked him by never even bothering to practice.

    When you were 10 years old he drove you all day, from soccer, to gymnastics, to one birthday party after another.
    You thanked him by jumping out of the car and never looking back.

    When you were 11 years old, he took you and your friends to the movies.
    You thanked him by asking to sit in a different row.

    When you were 12 years old, he warned you not to watch certain TV shows.
    You thanked him by Waiting until he left the house.

    When you were 13, he suggested a haircut that was becoming.
    You thanked him by telling him he had no taste.

    When you were 14, he paid for a month away at summer camp.
    You thanked him by forgetting to write a single letter.

    When you were 15, he came home from work, looking for a hug.
    You thanked him by having your bedroom door locked.

    When you were 16, he taught you how to drive his car.
    You thanked him by taking it every chance you could.

    When you were 17, he was expecting an important call.
    You thanked him by being on the phone all night.

    When you were 18, he cried at your high school graduation.
    You thanked him by staying out partying until dawn.

    When you were 19, he paid for your college tuition, drove you to campus carried your bags.
    You thanked him by saying good-bye outside the dorm so you wouldn’t be embarrassed in front of your friends.

    When you were 25, he helped to pay for your wedding, and he cried and told you how deeply he loved you.
    You thanked him by moving halfway across the country.

    When you were 50, he fell ill and needed you to take care of him.
    You thanked him by reading about the burden parents become to their children.

    And then, one day, he quietly died.

    And everything you never did came crashing down like thunder on your heart.

    If you love your dad, send this to as many people as you can. And if you don’t… then shame on you!!!

    I was just so touched, it moved me to tears.

    I was touched because my daughter thought of me, and acknowledged that I am at least trying to do what is right for her.

    But I was also touched because I don’t think that I can honestly say I got the same attention from my father. He was — is — unarguably a good man. He always cared and provided for his family, and his devotion to my mother, now that she is in a nursing home with Alzheimer’s disease, it truly inspirational. But in all my memories, he was in the background, working at his day job, or on one of his investments, in a never-ending battle to ensure that we wanted for nothing, and instead managing to deprive us of the most precious gift he had to offer — his time, his experience, his wisdom, his companionship.

    His friendship.

    And now, when he is in his eighties and despite living with us, his sense of duty means that he is not spending time with his grandchildren, again robbing them of the precious gifts he has, and robbing himself of the joy that they bring.

    But maybe there is one more gift he has given me. He has taught me that just doing your duty, earning money and looking after your family, although admirable and even necessary, simply is not enough. You need to give of your time, your attention. Your self.

    So Dad, I love you. Thank you for what you have done. I do understand it was the best you could do.

    I just wish I had been given the chance to know you better as a person.
    The following is a post that I made over on the Powerbasic programmer forums, hospital in response to Paul Pank’s posting asking dietary advice. Why he thought to ask about diet on a programming forum is beyond me. I have edited out the references to other posts but the entire thread can be seen at the PowerBasic Forum.

    First, site let me get some credibility here, page then make a disclaimer, then express my opinion.

    I am 47 and have been overweight pretty much all my life. My dad’s side of the family is very prone to Diabetes. In 1994, I was diagnosed with diabetes. At the time, I weighed about 130 kg (about 295 lb and I am 177 cm tall). I led a very sedentary lifestyle — my thinking was that exercise doesn’t really make you live longer, it just feels that way .

    When diagnosed with diabetes, I went through the brainwashing — err, pardon me — nutrition education. I was on 4 insulin injections a day, and had the whole food pyramid thing drummed into me. You know the one — lots of complex carbs with fibre (like vegetables and grains), far less proteins and even less fats.

    I followed the advice. Strictly. Under supervision. Really.

    And I ended up in 2003 weighing nearly 160 kg (360 lb)!

    So I took matters into my own hands, educated myself and did what I needed to do.

    Today, I weigh in at around 105 kg (240 lb: yes, that is over 50 kg/110 lb lost). I take no insulin or any other diabetic medication. My blood pressure is 110/70 and my bloodwork is terrific.

    Disclaimer: do your own research and make your own decisions. This may NOT be right for you!

    I read everything I could find. I went through Atkins and thought he had part of the picture. Then I found out about Glycemic Index (GI) and that completed the picture for me.

    Here’s how I understand it. Insulin is the hormone that allows sugars to cross over the cell membrane and be used for energy. If you don’t have enough, or it is somehow flawed, you are diabetic — the sugars accumulate in your blood while your cells slowly starve.

    But insulin does something else, too: it causes excess sugars in your blood to be stored as fat.

    This is important: it is the excess SUGARS (ie carbs) that are stored as fat, and this is done in the presence of insulin.

    To avoid this, you need to ensure that the food you eat does not cause a spike in insulin production. Foods that cause a rapid rise in insulin levels have a high GI. Glucose has the maximum of 100, and pure water has 0, with everything else inside that range. If you eat low to medium GI foods at each meal (so that the combined GI is low to medium) then your body’s ability to store fat is severely curtailed, so that even if you do eat a bit more than you absolutely need, most of the excess is not stored. That’s not to say you can pig out, but it does mean you don’t need to live your life counting calories or fat-grams or whatever.

    As for eating fats, the actual evidence of their effect on things like cholesterol is flimsy. Recently, here in Australia, the National Heart Foundation said words to the effect of “we were wrong: go ahead and eat the egg yolk too — it’s good for you and does not raise cholesterol”. My personal experience is that the level of cholesterol is largely genetic, and the environmental factors that influence it are far more likely to be related to simple starches (high GI foods) than fats. Consider this: what foods are high in fats and not also high in simple carbs? Pretty much nothing. If you eat a fast-food burger, the bun is not only white bread, it has added sugar. Fries? They’re potato! Chocolate? Sugar. Think about it.

    Calorie intake is important, but don’t get too hung up on it. If you restrict your calorie intake too much, your metabolism slows down, and stores fat more aggressively. It is better to eat regularly throughout the day, and DON’T SKIP BREAKFAST whatever you do! I try to eat six small meals every day. It is also good to give yourself a regular “free” day, where you don’t do any workouts and you eat freely. For me, that is Sunday. Nothing is off-limits on that day. The first few weeks, you go a bit nuts, but the novelty soon wears off, and knowing that you can have that chocolate “on Sunday” seems to make it easier to not have it the rest of the week. It is important to have more calories on these days, because you want to use it to kick-start your metabolism again.

    Hydrogenated oils are really bad karma. The evidence against them may not be concrete, but the anecdotal evidence is pretty overwhelming. I’ll eat butter, but not margerine.

    Finally, BMI is the biggest load of codswallop ever. It is a formulaic representation of the old height/weight charts which have been discredited for decades. You see, a given volume of muscle weighs about four times what the equivalent volume of fat weighs. So if you have a low percentage of body fat, you will way MORE than a person with exactly the same dimensions with a higher percentage of body fat. Elite athletes have TERRIBLE BMI scores — they are HEAVY for their height because they are very lean.

    And you want to be lean (and therefore heavy for your size) because that means that you need to burn more food just to live. As well as being stronger, both in terms of muscles but also in terms of calcium retention in bones, you will be able to eat more without putting on weight. So while aerobic exercise is good for you, losing fat really requires you to add muscle mass, and that needs strength training. Someone mentioned martial arts in a previous post — I would strongly recommend that, even if you are not particularly young. I started at 45, and am now a 1st Kye Brown Belt in the Kempo style. Find a good, family-friendly school. You will find that martial arts training is a really good mix of strength (resistance) and stamina (aerobic) work. Aikido is great — that is next on my list after I achieve Black in Kempo.

    To summarise (with all the disclaimers assumed):

    • eat low and medium GI foods. If you eat anything with a high GI, include something low GI with it at the same meal.
    • don’t stress about fat intake (be sensible here).
    • avoid hydrogenated oils
    • get into a regular, weight-bearing exercise regime
    • do NOT starve yourself
    • try to eat more, smaller meals
    • forget your weight — instead, focus on your belt size, the only figure you really need to care about
    • enjoy life – the point of looking after yourself is to enjoy yourself

    Again, do your own research.
    The following is a post that I made over on the Powerbasic programmer forums, hospital in response to Paul Pank’s posting asking dietary advice. Why he thought to ask about diet on a programming forum is beyond me. I have edited out the references to other posts but the entire thread can be seen at the PowerBasic Forum.

    First, site let me get some credibility here, page then make a disclaimer, then express my opinion.

    I am 47 and have been overweight pretty much all my life. My dad’s side of the family is very prone to Diabetes. In 1994, I was diagnosed with diabetes. At the time, I weighed about 130 kg (about 295 lb and I am 177 cm tall). I led a very sedentary lifestyle — my thinking was that exercise doesn’t really make you live longer, it just feels that way .

    When diagnosed with diabetes, I went through the brainwashing — err, pardon me — nutrition education. I was on 4 insulin injections a day, and had the whole food pyramid thing drummed into me. You know the one — lots of complex carbs with fibre (like vegetables and grains), far less proteins and even less fats.

    I followed the advice. Strictly. Under supervision. Really.

    And I ended up in 2003 weighing nearly 160 kg (360 lb)!

    So I took matters into my own hands, educated myself and did what I needed to do.

    Today, I weigh in at around 105 kg (240 lb: yes, that is over 50 kg/110 lb lost). I take no insulin or any other diabetic medication. My blood pressure is 110/70 and my bloodwork is terrific.

    Disclaimer: do your own research and make your own decisions. This may NOT be right for you!

    I read everything I could find. I went through Atkins and thought he had part of the picture. Then I found out about Glycemic Index (GI) and that completed the picture for me.

    Here’s how I understand it. Insulin is the hormone that allows sugars to cross over the cell membrane and be used for energy. If you don’t have enough, or it is somehow flawed, you are diabetic — the sugars accumulate in your blood while your cells slowly starve.

    But insulin does something else, too: it causes excess sugars in your blood to be stored as fat.

    This is important: it is the excess SUGARS (ie carbs) that are stored as fat, and this is done in the presence of insulin.

    To avoid this, you need to ensure that the food you eat does not cause a spike in insulin production. Foods that cause a rapid rise in insulin levels have a high GI. Glucose has the maximum of 100, and pure water has 0, with everything else inside that range. If you eat low to medium GI foods at each meal (so that the combined GI is low to medium) then your body’s ability to store fat is severely curtailed, so that even if you do eat a bit more than you absolutely need, most of the excess is not stored. That’s not to say you can pig out, but it does mean you don’t need to live your life counting calories or fat-grams or whatever.

    As for eating fats, the actual evidence of their effect on things like cholesterol is flimsy. Recently, here in Australia, the National Heart Foundation said words to the effect of “we were wrong: go ahead and eat the egg yolk too — it’s good for you and does not raise cholesterol”. My personal experience is that the level of cholesterol is largely genetic, and the environmental factors that influence it are far more likely to be related to simple starches (high GI foods) than fats. Consider this: what foods are high in fats and not also high in simple carbs? Pretty much nothing. If you eat a fast-food burger, the bun is not only white bread, it has added sugar. Fries? They’re potato! Chocolate? Sugar. Think about it.

    Calorie intake is important, but don’t get too hung up on it. If you restrict your calorie intake too much, your metabolism slows down, and stores fat more aggressively. It is better to eat regularly throughout the day, and DON’T SKIP BREAKFAST whatever you do! I try to eat six small meals every day. It is also good to give yourself a regular “free” day, where you don’t do any workouts and you eat freely. For me, that is Sunday. Nothing is off-limits on that day. The first few weeks, you go a bit nuts, but the novelty soon wears off, and knowing that you can have that chocolate “on Sunday” seems to make it easier to not have it the rest of the week. It is important to have more calories on these days, because you want to use it to kick-start your metabolism again.

    Hydrogenated oils are really bad karma. The evidence against them may not be concrete, but the anecdotal evidence is pretty overwhelming. I’ll eat butter, but not margerine.

    Finally, BMI is the biggest load of codswallop ever. It is a formulaic representation of the old height/weight charts which have been discredited for decades. You see, a given volume of muscle weighs about four times what the equivalent volume of fat weighs. So if you have a low percentage of body fat, you will way MORE than a person with exactly the same dimensions with a higher percentage of body fat. Elite athletes have TERRIBLE BMI scores — they are HEAVY for their height because they are very lean.

    And you want to be lean (and therefore heavy for your size) because that means that you need to burn more food just to live. As well as being stronger, both in terms of muscles but also in terms of calcium retention in bones, you will be able to eat more without putting on weight. So while aerobic exercise is good for you, losing fat really requires you to add muscle mass, and that needs strength training. Someone mentioned martial arts in a previous post — I would strongly recommend that, even if you are not particularly young. I started at 45, and am now a 1st Kye Brown Belt in the Kempo style. Find a good, family-friendly school. You will find that martial arts training is a really good mix of strength (resistance) and stamina (aerobic) work. Aikido is great — that is next on my list after I achieve Black in Kempo.

    To summarise (with all the disclaimers assumed):

    • eat low and medium GI foods. If you eat anything with a high GI, include something low GI with it at the same meal.
    • don’t stress about fat intake (be sensible here).
    • avoid hydrogenated oils
    • get into a regular, weight-bearing exercise regime
    • do NOT starve yourself
    • try to eat more, smaller meals
    • forget your weight — instead, focus on your belt size, the only figure you really need to care about
    • enjoy life – the point of looking after yourself is to enjoy yourself

    Again, do your own research.
    The wiki is now online at http://www.jimako.com/wiki, try
    where I hope to maintain more of a presence than I have in this blog. The bottom line is that, treatment most of the time, I am just too busy to journal what I am up to in the blog, and most of my ramblings are probably not terribly interesting to most people.

    So, if you do want to keep in touch, check out the wiki, which will probably be updated more frequently than this blog.

    What I would really love to see is more of an integration between the blog and the wiki. I have tried to tinker with the PmWiki software to see if I can get a blog-like experience from it, but while you can do SOME sort of blog-like activities, it is just not designed for that. If someone could skin WordPress to look like my wiki, well, that would be just too cool.
    I have been reading a great book over the past couple of days. It is called The Best Software Writing I and I picked it up at the local Borders when I dropped in to browse as I am wont to do on the odd occasion. Reading it fired up the creative juices, diagnosis so I thought I would put finger to keyboard about something that has been gnawing at me for a while now: the fact that we seem to be making things more complex than they need to be because of some misguided attempt to model the "real world".

    Now, I am the first to admit to being an old-world developer. I learnt how to program in the late 70s, at at time when OOP was simply unheard of out in the wild. I clearly remember the famous hot air balloon cover on the issue of Byte that introduced Smalltalk. Yes, not only was I alive then, I was old enough to buy Byte and read it.

    I have worked through the evolution of our craft and the changes in the way we approach the development of software. By virtue of the fact that I learnt to program before there was OOP, intially I had a tough time really understanding how OOP worked, simply because there was a lot of unlearning that I had to do. It took me a while, and there were many times when I told myself that now I ‘got’ OOP, only to admit a little while later that I really didn’t get it at all.

    If that sounds at all negative about OOP, it isn’t meant to. I am actually a big proponent of the benefits of OOP and think that the binding of data with the procedures that operate on it is A Good Thing.

    What I am finding, however, is that a new generation of programmers who don’t know anything except OOP are losing track of the objective. When you learn OOP, you are inevitably given examples of real-world objects that you try to model. I think that if I ever see another example of an Animal class, with Dog and Cat descendents, I will scream, even though I actually wrote a student manual for a VB4 course that used these self same classes. We learn about inheritance and its use to create polymorphic behaviour by having Cat.Speak emit a mieaow while Dog.Speak emits a woof. Or we have traffic lights control their own sequencing by sending messages to each other. All very cool.

    Then off we go to do commercial programming. Except, there is a real disconnect at this point. ‘EDP’ (to use an outdated but nonetheless expressive term) is not the same as traffic control. In most business data manipulation, the entities we are dealing with are nothing but data points. The only reason the system exists it to maintain a repository of data, furnish a controlled view into that repository and provide a mechanism to allow a predifined set of transformations of that data to take place in a controlled manner. There are no dogs or cats in the wild that we are trying to model. What exactly does an account do when it is not being "modelled" by a piece of code? The answer, of course, is nothing at all — it just sits quietly in a database somewhere.

    I have seen too many systems that model an Account object with all sorts of complex behaviours. From one perspective, this can be useful — we can encapsulate all the things that we can do to an account as methods of the Account object, thereby binding the data with the code and (at least in theory) hiding the implementation details. I have no problem with this; in fact, this is exactly what makes sense.

    The problem arises when we refuse to acknowledge that the account lives in a database with a whole lot of other accounts. Worse still, we refuse to acknowledge that the database exists at all. Instead, we abstract it away with a "factory" the magically produces Account objects. It can give us a particular Account object if we can give it some distinguishing attribute, like an ID. But heaven forbid that we ask for any complex filtering — why, that’s almost like SQL, and we wouldn’t want to pollute our neat, abstract, HashMap in the Sky with any of that old "relational stuff".

    So instead of crafting a simple SQL statement that reflects the set of data we actually need, we write code that does all but the simplest filtering on the client side. You don’t want all the columns of data?  Who cares? Just don’t reference those attributes of the objects. You don’t want all the rows? Well, use one of the simple factory methods to do a first cut at the filtering, then just iterate through the list of objects that are returned and remove the ones you don’t want.

    Does anybody else see a problem here?

    Decades ago, we came up with a way to manage operations on tabular data. A whole relational alegbra was developed that provided a clean set of operations that could be requested by a client program, so that only the data it actually wanted would be returned by the database. The SQL language provided a reasonably straightforward way to express those operations, and databases got really, really good at processing SQL, so that, at least in most cases, they could quickly and efficiently get just this required data together. That’s what they are designed to do, and they do it very well. And when they have done this, just that data that is actually required goes over the wire to the program that requested it, which in turn can be simpler because it doesn’t need to do the whole post-processing dance.

    Today, OOP developers think that their code has somehow become impure if it contains an SQL statement, or acknowledges the existence of a database, or a table, or a row or column. Yet these are the actual big-O Objects that are being manipulated. The row in the table (OK, the rows in related tables in the database) are the account. That is the object we are dealing with. Why do we feel the need to abstract it away?

    It’s not like a cat. It is not practical for a program to deal with an actual Cat object. The Cat interface is not well understood, and the Cat Query Language is still in its infancy. When dealing with cats, it makes sense to create a simpler abstraction of a Cat, that models all the attributes of a real cat that we are interested in, and use that as a surrogate for a real cat in our program. Besides, cat fur really clogs up the fan vent in a computer case.

    An account, on the other hand, like a large number of the "objects" we deal with in business software development, is quite easily accessible directly.

    We don’t need no steenking abstractions.

    Why do some people just find it hard to admit they’ve made a mistake? We all do it — heaven knows I have, prosthesis on many occasions and in many contexts. Yet for some reason, prostate there are those amongst us who feel that any suggestion that they made an error needs to be shouted down forcefully lest they be stigmatised as failures.

    A mistake is not a failure. A mistake is an opportunity to learn, advice to grow, to re-focus, to improve. It reminds us that we are not infallible, and injects a little humility into our souls.

    The failure is in not heeding the message that the mistake is trying to convey. Cosmic karma is at work here. The universe starts with a gentle tap on the shoulder trying to get your attention. If that doesn’t work, then a rap across the knuckles comes along, followed by a clip behind the ear. Pay attention to what you are being told, because if you ignore all of these, then the speeding truck is on its way.

    I have yet to see a more effective way of dealing with a mistake than simply admitting to it, apologising sincerely to those impacted by it, and thinking about why it happened and what lessons need to be learnt. Not only is this in keeping with the natural operation of the universe, it builds your own moral fibre, and earns you respect from those around you.

    Pointing fingers at others, reaching for a scapegoat, making excuses, or just plain claiming you make no more mistakes than others do just doesn’t cut it — not only do you come across to others as someone who lacks integrity, you train your mind to react inappropriately and get further out of sync with the world around.

    And that is not where you want to be.

    … then it’s the map that is wrong.

    Last week, visit this my son went for an interview for entry into one of the top academic high schools in this state, medicine and I needed to kill a couple of hours. I therefore went into a local Borders bookshop, geriatrician grabbed a book almost at random and sat down with it in the embedded Gloria Jean’s with a cup of coffee. I don’t even remember the name of the book; it was something like "30 Things You Need To Know Right Now". What has stuck in my mind is the first of these "things".

    If the ground doesn’t correspond to the map, then it’s the map that is wrong.

    Sounds simple, doesn’t it?

    I must admit that I didn’t read much past that opening chapter heading, because I had one of those "Aha" moments (or more like one of thise "D’oh" moments, I guess).

    Everyone today seems to have a preferred point of view about how the world works. Based on that view, plans are drawn out that attempt to map out what we will do and the outcomes that we expect. I admit to having a particular issue in mind here — the issue of "professional managers" that I have blogged about before, and I will use this issue as an example — but the observations that I am making are more generally applicable.

    Let me go through a concrete example here. As I have already documented, I believe that a technical activity like software development cannot be managed by a generalist manager. But my view is not universally subscribed to — shocking, I know, but not everyone agrees with my every view, at least not yet, although I continue to work on it.

    So in a particular workplace that I am familiar with, despite my view, there has been a definite move over the past several months away from using managers with a technical background and towards employing generalist managers, people who are in fact actively TRYING to remain non-technical, and believe that major software development projects should be managed in the abstract using general project management techniques.

    For a while, I have been trying to argue against this policy, and several others have voiced concerns as well. But this single statement hit me like a cricket bat over the head.

    If the ground doesn’t correspond to the map, then it’s the map that is wrong.

    I don’t need to argue the view on a "first principles" or "logical" basis. I simply need to look at what is happening in the real world.

    In other words, I need to stop focusing on the map and look at the ground.

    You see, there are a few very clear indicators about the health of a software development project, and they can be measured reasonably easily. Those indicators are not universal, as every human endeavour is a trade-off between competing requirements. But for any given project, there is a specific range of settings on the various axes that we are aiming for, and we can usually gauge how we are tracking.

    So if we are aiming for high quality, then we can look at defect rates. If speed of delivery is our focus, then we can look at function points delivered per release. If we are looking at long term project sustainability, then developer satisfaction and retention rates (or, inversely, dissatisfaction and staff turnover) can be examined. If we are concerned with customer satisfaction, we can ask the customer for subjective or objective feedback.

    If we look at what data we have "before" (that is, with technical managers) and "after" (with generalist managers), we can see which set of conditions moves us closer to our desired outcomes. And if one of them is significantly closer to the way we want to be, then all the arguments and logic about which management strategy is best become irrelevant. It’s like arguing about which map is more correct without looking at the ground. The correct answer can be determined quite unambiguously by comparing the maps to the ground.

    Similarly, if we look at the health of the project, using whatever parameters we want to define health, under the two management styles, we should be able to discern which of the styles is better in this context.

    Now, let me be the first to admit that this metric will only look at the relative performance of the particular individuals involved, and on the project under examination, and a single set of observations like this cannot be extrapolated safely to the broader project management landscape. However, I am really interested in just this one particular set of variables, so that’s perfectly OK.

    I would be interested, however, in collating more information from a number of different projects that have tried both management types to see if there is any commonality. With enough separate data points, we might well be able to draw some generally applicable conclusions.

    Feel free to leave any anecdotal data in the comments.

    I’m a big fan of Ruby, dosage the language.

    I’m really impressed with the potential of the Rails framework (although to be honest there seems to be a lot of voodoo going on behind the scenes, diagnosis which is probably just an indication that I have not yet done enough with this framework to be comfortable with it).

    But there is no denying the reality that, for most of us, adopting Ruby and RoR is not a simple decision, because we already have code that has been developed atop a Java web stack.

    If we are looking at a new project, and there is some ability to absorb the risk of going with a new technology stack, I would be the first to suggest that RoR be given serious consideration. On the other hand, if we are involved in the on-going development of a Java web application that has been going on for several years, does it make sense to try to integrate a new stack into the mix?

    Let me set some parameters. You have a successful product that is continually being improved. Using “best practices” (I’ll come back to that term in another post), the application has been developed using an MVC framework — let’s say Struts, JSP and Hibernate as a concrete and all-too-common example.

    Now, we want to make some changes as a result of customer feedback. Typically, these changes are either new features or modules, or else changes to the existing functionality.

    Changes to the existing functionality are hard to do in any other technology. Sure, if the changes are broad enough, it might make sense to redevelop one or more modules from scratch; in that case, of course, we can treat it the same way we would treat the development of a new feature.

    So, for a new feature, what alternatives do we have?

    We can certainly continue on with our existing technology stack. In many ways, this is the low-risk option, because we know the technology. We know the tool-sets, we have knowledge within our development team, and we have historical data about how quickly we can do things using that technology. And let’s not forget that the stack itself is well-proven, because we (and countless others) have deployed applications on that stack and we know how the stack scales, how it deploys, how it responds to machine and network resource allocations. There is a lot of value to maturity.

    But is it really a low-risk option? What if the development velocity is not fast enough? Sure, we have good predictability, but if our predictions are that we can’t do it as quickly as we need to in order to satisfy the customer, or prevent the work being assigned off-shore, then surely persisting with that technology is in reality the high risk option.

    And here’s the real issue. Java web development using the classic development stack is just not fast enough. I’ve heard the arguments — you need to do all the fancy plumbing and documentation / annotation so that the app scales and is flexible and maintainable when it gets hit by millions of users per minute. The reality, however, is that most applications never need that scalability, especially if they are not finished because application development is too slow.

    So what do we do? Is there some way to incorporate some of the really rapid web application development techniques into an existing Java web application?

    I think that we are at a difficult time in Java web development. We have a lot of systems that have been developed over a long time (“long” being relative to the rate of change of software development, of course). While these systems are often still in active enhancement, they are also in a very real sense legacy systems, built using tool sets, frameworks and architectures that, well, seemed like a good idea at the time. Looking back at what we have done, and also looking at all the shining new toys all the new kids are playing with that show just how much faster web application development can be, we can’t help but feel frustrated and itchy to do something, well, different.

    At the same time, we have some interesting things “just around the corner” in the Java space. But we need something we can use right now.

    I see JRuby is coming along in leaps and bounds. This is an implementation of the Ruby language for the Java Virtual Machine. It is almost at the point that it can run Rails applications. However, I don’t see a clean way to do new-feature development for an existing web application using Rails, even if it is on the JVM. Another very nice dynamic language, Python, has a JVM implementation in Jython, but this is languishing and seems to have been largely orphaned when its initial developer switched focus to IronPython, which is an implementation for the .NET platform.

    Groovy is coming along nicely, but slowly. It is likely to be an “official” scripting language as a result of having a JSR. Also, it has a Java-like syntax, which means that there is a shorter pick-up time required for Java developers.

    If I thought that language is the limiting factor, then I would look at Groovy because it has a lot of the syntactical conveniences of the popular scripting languages with full access to existing objects that have been coded in Java (including the Java libraries).

    However, while I think Java can be too wordy, requiring lots of boilerplate code in some circumstances, I am not at all convinced that this is the major reason that web development in Java is too slow.

    In reality, I think that the real reason web development in Java is too slow is that we are making it too complicated. The real reason that frameworks like RoR are so incredibly productive, in my opinion, are more related to the use of very simple ORM designs like ActiveRecord, and the Convention over Configuration philosophy.

    Sure, Hibernate is REALLY powerful. But it is not ideal for all sorts of database access, at least not when used naively. Sometimes, a simple SQL query, processed as JBOF (Just a Bunch Of Fields, and yes, I did just make that up) is totally appropriate.

    Consider for example presenting a user with a filtered, paged list of widgets. In the prehistoric era of web development (that is, about 8 years ago, and using VB6 COM behind IIS/ASP) I designed a relatively simple, generic technique. I created an SQL statement by putting together the WHERE clause dynamically. I then did a SELECT statement, retrieving only the IDs that matched the criteria. IDs were just 32 bits each, so even a million of the suckers was just 4M — most lists were a few hundred to a (very) few thousand rows. I just stuck them in an array and stuffed them into the session. Then, paging was simple: just calculate the array indexes that correspond to the desired page, create an SQL statement that retrieves only the ID and the columns required for the list display (using an SQL WHERE ID IN … statement) and displayed the list. All this is totally generic, it scales REALLY well, and has not let us down after years of very heavy use in the field.

    More recently, and in the Java world, we end up retrieving lists of objects. We rely on Hibernate or the ORM de jour to do magic, multi-level caching and lazy object instantiation and hope that it all works. And then we dump the list into some magic JSP taglib that does sorting in memory. And when the list gets to a few hundred items, the list takes MINUTES to display, and customers are unhappy, and developers say “you didn’t specify performance criteria”, and analysts say “but of course it has to handle more than a dozen items in a list”, and you need to divert resources to do major investigation and refactoring or redevelopment, and you start to think that things are not meant to be this hard.

    In business application development, the needs of the application for data access are not complex. We need to get filtered lists of items, then we need to get complete individual items. That’s pretty much it, and that’s what DATABASE servers do — we should let them do their job and not try to replicate that in the application. Updating is only a little more complex.

    The other lesson that we can learn from RoR is that we seriously need to tame the configuration frenzy that Struts brings. I need more time to think about this, but I think that a good way to begin simplifying this in an existing product is to add a single Struts action that further parses the request URI and uses some convention to identify the class and method that should handle it. That class could be written in Java, or any of the new, JVM-hosted scripting languages. Do it well, and write a suitable class loader, and you could even hot-deploy a URI request handler class or JAR file.

    The reason that I am considering this is not because I don’t want to use an existing framework like Ruby on Rails (or for that matter Grails, Turbogears or Django). It’s that I need to be able to integrate whatever framework we use into the application as it exists so far, and everything I see (and my gut instinct) tells me that these frameworks are good for new projects but are likely to be a bitch to configure and integrate with a Java/Struts/JSP stack.

    I have not yet clarified my own thinking about all this, but I wanted to post it to get some feedback. What do others think? Am I alone in thinking that we are making Java web development harder than it needs to be?
    I really like Python, somnology but was not aware of this little hidden easter egg. If you fire up the interactive interpreter, and type “import this”, you get this wonderful printout to the console:

    >>> import this
    The Zen of Python, by Tim Peters

    Beautiful is better than ugly.
    Explicit is better than implicit.
    Simple is better than complex.
    Complex is better than complicated.
    Flat is better than nested.
    Sparse is better than dense.
    Readability counts.
    Special cases aren’t special enough to break the rules.
    Although practicality beats purity.
    Errors should never pass silently.
    Unless explicitly silenced.
    In the face of ambiguity, refuse the temptation to guess.
    There should be one– and preferably only one –obvious way to do it.
    Although that way may not be obvious at first unless you’re Dutch.
    Now is better than never.
    Although never is often better than *right* now.
    If the implementation is hard to explain, it’s a bad idea.
    If the implementation is easy to explain, it may be a good idea.
    Namespaces are one honking great idea — let’s do more of those!
    >>>

    Enough said.
    I can’t believe that it has been over three months since the last post. I’ve been really busy, for sale and done a few cool things, cost but did not stop to write about them. I’ll fix that over the next few weeks, and take the time to write down some of my current thinking.

    In the meantime, you might like to look at a site I am setting up for the Central District of the United Grand Lodge of Victoria at www.centraldistrictvic.org.  I am using WordPress (the same software that powers this blog) as the entire CMS for that site, forgoing PmWiki. I am impressed with just how powerful that software is, and while it does not have the flexibility of a Wiki, it is probably easier to use for non-technical users.

    More soon…
    I can’t believe that it has been over three months since the last post. I’ve been really busy, for sale and done a few cool things, cost but did not stop to write about them. I’ll fix that over the next few weeks, and take the time to write down some of my current thinking.

    In the meantime, you might like to look at a site I am setting up for the Central District of the United Grand Lodge of Victoria at www.centraldistrictvic.org.  I am using WordPress (the same software that powers this blog) as the entire CMS for that site, forgoing PmWiki. I am impressed with just how powerful that software is, and while it does not have the flexibility of a Wiki, it is probably easier to use for non-technical users.

    More soon…
    After a bit of playing around, tadalafil I found that I needed a few more features than WordPress provided, therapist
    so the site was transferred to Drupal. This CMS requires a bit more work to get going, but boy does it have functionality. If you are a web master, you really should check it out.

    Posted by jimako @ 12:35 pm

  • Leave a Reply

    Your email address will not be published. Required fields are marked *

    This site uses Akismet to reduce spam. Learn how your comment data is processed.

 

This is my private blog and web site. You can find out more about this web site and its author on the About page.


Interested in where the name comes from? See the What's a Jimako page.


Feel free to browse the site to see what else is here, or peruse the random ramblings in the blog.


Categories

Archives

 
WP_Modern_Notepad