What DevOps Means for Static Analysis
Editorial Note: I originally wrote this post for the NDepend blog. You can check out the original here, at their site. While you’re there, have a look at NDepend’s static analysis offering.
For most of my career, software development has, in a very specific way, resembled mailing a letter. You write the thing, and then you go through the standard mail piece rigmarole. This involves putting it into an envelope, addressing the envelope, putting a stamp on, it and then walking it over to the mailbox. From there, you stuff it into the mailbox.
At this point, you might as well have dropped the thing into some kind of rip in space-time for all you understand what comes next. Off it goes into the ether, and you hope that it arrives at its destination through some kind of logistical magic. So it has generally gone with software.
We design it, architect, and lovingly write it. We package it up, test it, correct defects in it, and then we call it done. From there, we fire it into the mailbox-black-hole of the software world: operations. They take it and deploy it, or whatever, and then, by some magic we don’t concern ourselves about, it runs in the real world. Or so it has generally gone.
Problems with the Traditional Approach
With the benefit of hindsight, you can probably guess the main problem with this state of affairs. So rather than enumerate it dryly in a series of bullet points, let me offer it up in story format.
You work as an application developer in some very large enterprise. There, you build web apps. And you take pride in your work. You write clean code, you maintain the unit test suite, you collaborate dutifully with QA, and you generally do your best.
In fact, this effort even extends beyond your own dev environment and into as many environment as you can see. You run load, smoke, and integration tests in QA and sandbox environment. And, as a whole unit, your team does everything it can to ensure the integrity of the work. But beyond the pre-prod environment, the fate of your application becomes an utter mystery. Some group of folks located in a different timezone take it from there. You wish it well as it heads to production.
And then, one day, six months later, you get some incident report. Apparently, some guy in Hungary or somewhere was doing something when somehow he get a null reference exception. But don’t worry, here’s a brief description of what he said and a few thousand lines of some random log file. Good luck with your repro!