I’m working on a series of posts that outline a book’s worth of suggested curriculum on how to learn some of the technical practices that Agile Programming involves. The first post is here.
The Myth of Affordable Technical Debt
Along the way, I’ve re-discovered that too, too many software professionals still misunderstand, fundamentally, what Agile Programming and Software Craftsmanship are about, and why we bother with them. So I’m summarizing my view on that here. I’m not recapitulating the history now (later, perhaps). I’m just trying to gently make the case that sufficient long-term quality is something we can never not-afford.
In the heat of the production pressure to get a User Story out the door by hook or by crook, the discussion about “how much craftsmanship can we afford here” does keep arising (with the best intentions on all sides, no doubt). That’s my context for how and why programmers should learn deep craft. I suggest that almost no-one in software is ready to ask that question.
By Agile Programming, I Do Mean Computer Programming
My definition of Agile Programming is computer programming done at a high level of craft. (Note that in this series of posts, I am not talking about the entire superset of Agile Software Development practices and principles, some of which are technical, and some of which are not.)
Another definition of Agile Programming is Clean Code. These are ways to think about what it is. But why do we do it? It really is all about the smoothest flow of value through the code and the team. It is about highest ROI, and lowest TCO. Put another way:
Any programming practice or choice that does not make or save money for someone, somewhere, someday is not agile, and is not software craftsmanship.
Truly: Why Do we Bother? Are we Being Quality Fanatics?
We are not being fanatics. We are avoiding lots and lots of pain.
To a new regular-army combatant fresh to Guadalcanal in 1942, it may appear that the combat-veteran marines are completely obsessive-compulsive about cleaning their weapons. That’s because those fresh arrivals have not had their weapons jam frequently enough in heated enough battle in a nasty jungle. Field stripping a weapon in a way that appears obsessive and fanatic is just pain prevention. Pure and simple.
The idea of the high software craft inherent in true Agile Programming is to provide exactly, and only, the highest short-term ROI and long-term ROI, and the lowest short-term and long-term TCO for a codebase as simply another asset to be managed (around which, for example, CAPEX and OPEX expenditures must be carefully predicted and managed these days).
Too frequently, we are asked to build straw houses when only brick houses will do, and we have no way of making it clear how false an economy this is. In a comment thread on a great blog post of a friend of mine’s, the debate rages about, essentially, the economics of Clean Code (“CC”) versus Quick and Dirty (“QD”).
Two things: I have frequently found that the advocates of QD have not bothered to learn CC deeply. They are arguing from at least partial ignorance and fear. (That is not true, BTW, of Naresh Jain, who is a very advanced Agile Programmer.) If you really are as good at Agile Programming as Josh Kerievsky, or Ron Jeffries, or Mike Hill, or Naresh Jain, then yeah, I’m willing to have User-Story-specific discussions about specific short-term “speed vs quality” tradeoffs. Otherwise, I’m not willing to have that discussion with you. All these guys have spent more than 10,000 hours test-driving. Once you’ve done that, let’s talk about CC vs QD again.
Only if you are deeply, deeply expert at test-driving clean code does it make sense for you to talk about breaking the rules. Only then do you have a feel, and deep knowledge about, the rules for breaking the rules.
The other thing is that QD experts (the Duct-Tape Programmer) are not taking long-term ROI and TCO into account fully enough. Yes, I want to ship product as regularly and quickly as I possibly can, with least thumb-twiddling. But no, I don’t want an asset in my portfolio made of duct tape and WD40. What’s the duty cycle on that thing? One release? Two?
The QD experts are arguing that QD works for a User Story, or an Iteration, or a Release. Well, yeah, you can have a roof over your head faster if you build with straw. So what? Is that a way of saying “I don’t believe in storms.” ? In the specific context of getting good-enough releases out the door for startup ventures, are we making it clear enough when we are distinguishing between prototypes designed to win investment capital, and production code designed to live for 25 releases?
The questions “How much craftsmanship can we afford for this Iteration? or this Release? or this User Story?”, when asked about anything but spikes or prototypes, are nearly always premised in false economy.
As my friend Dave LeBlanc says: Later == Never. You will never be able to “Refactor” your straw house into a brick house. It will need to be rebuilt from scratch, eventually. Factor this into your ROI and TCO estimates. Oh, again, in the context of CC vs QD for startups, there is another sad corollary I’ve seen borne out time after time:
Every prototype ships, and becomes long-term production code. Especially for boot-strapped startups, whose investors will not agree to purchase or fund prototypes.
High software craft, Agile Programming, are not knob polishing, or gold plating. Agile Programming is about getting it right the first time, and getting it right over and over again. It is about optimizing the long-term return on an investment.
How come our codebases cannot last as long as our best cars? Why do most codebases that have not exhausted their business value end up going through expensive, dangerous rewrites? Aren’t these rewrites fundamentally avoidable? You bet they are.
The fundamental unit of waste in software development is also the fundamental unit of denial: the gigantic codebase rewrite.
We can do much, much better than that. That’s what Agile Programming and software craft is about.
This level of dedication to quality is very much like Honda dedication to quality. It’s not about burlwood on the dashboard, or spoilers on the trunk, or pinstripes down the sides (though if you want those in the GUI, we can do that too, as in an Infiniti). It’s about a 300,000-mile-duty-cycle drivetrain, come hell or high water. It’s about the industry growing out of its addiction to rewriting business-valuable codebases after a few releases, because we can’t work them anymore.
How many 1993 Chevies does anyone in Michigan see out there on the roads, still purring along with few issues? Few. But you know what? There are still lots of 1993 Toyota Camries out there on these snowy, badly-maintained roads. Until recently I drove one every day (and I still own it as a spare-loaner-beater). It’s a little dinged up. And the AC just gave out (after 18 years!). But it also still starts in 6 degree weather, and runs smooth at 80mph, and gets 30mpg. Because those Camries were made with highest long-term ROI and lowest long-term TCO in mind.
So, throughout the series of “How To” posts, please keep this definition of the what and why of Agile Programming in mind.
I’m writing an article on how developers can sell agile to a CFO, & talked w/ my own company’s CFO. He said agile is an easy sell to CFOs. It offers transparency, measurability, predictability, the ability to build only what we need right now. He says developers shouldn’t say “Let’s do agile because we want to do it” but show how it helps the CFO with future forecasts and planning. He says the ability to quantify technical debt is “music to a CFO’s ears” and had no trouble understanding our need to take time to learn and use good craftsmanship practices, to refactor, to take time to work on reducing our technical debt.
So to me it’s not about being quality fanatics. It’s about being engaged members of our business. It’s best for the business to have a team of good people who are committed to the highest possible quality code and make that commitment mean something. We shouldn’t demean business managers by thinking they won’t understand the value of the agile approach, delivering high-quality value frequently at a sustainable pace and adapting to ever-changing business needs.
Completely agree with this article. Software craftmanship is something that is rarely talked about and less understood.
Quality code is about thoroughness, it’s about being ‘complete’ and really ‘done.’
I agree with Lisa, it’s about educating the business of what they really want: Good clean code, and that, my friend, takes extra steps to do.
Well said. I entirely agree with the arguments you make here. And with the frustration at being (sometimes willfully) misunderstood.
I wonder. Words like “quality” and “clean” carry a strong subtext about morality. Advocating that we create clean, quality code-bases is perilously close to saying that we want people to be more good, and that is off-putting to others, and especially so to folks who are suspicious of the movement.
I am sore tempted, as is my wont, to create a neologism to describe what we’re valuing. I feel we need a word or phrase that is not moral in its content. Something that is *not* a marketing phrase. “Mercenary coding,” or something else. “TDD’d code” begs the question. — GeePawHill
Lisa, Agile Scout, and Mike: Thanks so much for the thoughtful comments.
If my language sounds alienating to business stakeholders, then doh! I need to rephrase.
I totally believe, Lisa, that your enlightened CFO is an easy sell, which is awesome. I don’t get C-level resistance to quality-as-good-business. I get it from low-level project managers and product owners, and frequently from programmers themselves.
And, I am welcome to neologisms, turns of phrase, and any other rhetorical device that is truthful and gentle, forthright and non-threatening.
–Patrick
You make an excellent case. I want to learn to do that, so I’m thinking I’ll read this about 25 times. Thanks, Patrick.
Also looking forward to Hill’s neologism emerging. That’s something that’s been bugging me.