The Inefficiency Equation

A developer goes to work. They arrive, sit down, and start right away at something. It could be e-mail, or a quick chat with coworkers, or a daily scrum. The coding begins and the interruptions start. Someone comes to ask a question, a server has failed, the build breaks, the code doesn’t work as documented, and the list of things goes on for stacks of paper.

How does a developer deal with this? It’s an ongoing question. Everything from Six Sigma, Lean, to eXtreme or Scrum Agile Process all are designed around combating these issues along with many others. The question among all these processes and plans and other ideals is, “What percentage of time can we regain for a developer?”

I’m going to make a WAG and state that in most development shops today, that aren’t utilizing effectively one of the methods mentioned above, 40% of a developers time is available to regain for productive use. Does that seem like a lot? I don’t think so, because the amount of time in an average developer’s day is really not spent doing development. Generally it isn’t even spent solving problems they should be working on. The average developer, in the average developer’s environment, spends a large percentage of their day just dealing with day to day operational needs; the build server, breaking the build, fixing the build, getting source code, checking it in, tracking bugs, bug fixes, eating lunch, communication about unrelated items that are causing work to stop, and on and on.

So how can these things be remedied? I’m going to cover a few ways, but from a purely toolset specific sense. The tools that a developer uses during the course of a day are extremely important to the efficient usage of time.

Tool Integration

It is absolutely pivotal in today’s development environment that at least the majority of the development tools integrate together in some smooth way. If the system wasn’t so bug prone, Visual Studio Team Foundation Server would probably be the king of the stacks, but it isn’t. However, Visual Studio is still one of the premier integrated development environments out there. With that one can use a number of other tools that integrate smoothly into the environment.

There should be, to gain maximum efficiency in time usage, a smooth integration between QA, bug tracking, unit testing, builds, build reports, project reports, and code statistics. There are a number of tools out there that perform these tasks admirably. The key though, is to get them to perform these tasks while integrated into the entire development process.

Test Coverage, Regressions, and Black Boxes

Developers spend an inordinate amount of time trying to find where problems actually occurred. This is, to put it kindly, absolutely unacceptable in today’s development environment. A developer should be able to pinpoint a bug in minutes. But a developer cannot be expected to do this without unit test coverage, regression test ability enabled by a high percentage of test coverage, and things being appropriately isolated into their respective black boxes.

Which brings me to one of my points of continued amazement of how many shops don’t do legitimate unit testing. Many development shops spend 3-8x as much time in the fix cycle part of quality assurance and regression. Literally for every hour a solid team that has unit test coverage, clear separation of concerns and functional service isolation spends, other teams spend 3-8 hours. This IS NOT AN EXAGERATION! This is one of the largest elements in modern software development that needs pushed, unit testing is no longer an optional part of development.

…short summary…

Enough of me rambling on about this now. Between the two items above, that should decrease that 40% of time waste drastically. I’m not sure how much, but it is a huge step forward.

Visual Studio Project and Solution Guidelines :: Tip o' The Day

Over the years I’ve tried various configurations for projects and solutions in Visual Studio. One thing I’ve noticed is there are definitely good ways to do things and bad ways to do things. My intention is to, with this entry and others, lay out what is good, efficient, and elegant practice in putting together Visual Studio Projects. Since I haven’t posted a tip o’ the day in a long while, I figured that would be a great category to drop these into.

Don’t Add Projects Whimsically!

Projects after a while start to cause all sorts of problems. There are interdependency issues that come up, possible circular references, reference maintenance, obfuscation of logic, namespace telescoping, and the list goes on. Keep project organization simple. In MVC for instance, often a solution becomes littered with a project for the model, the assembler for the model, a project for the view, and maybe ever several projects for the controllers.

All of that should be fine in a single project! Yes, one single itty bitty project. The project can then be built into a single DLL and life is thus simplified!

So don’t add projects “just because”.

HTC Mogul, Hard Reset – AGAIN

I own, and use heavily, a Sprint HTC Mogul Phone. It runs Windows Mobile on it, and amid my normal complaining it is an alright phone. Really though, I shouldn’t even say it is an alright phone, the phone is great, the operating system is what leaves a lot to be desired. In the time I’ve had it, which amounts to almost 8 months now, I’ve had every other day soft reboots, two hard resets, and numerous other smaller issues, lock ups, slow response, and other operating system related issues.

Recently I needed to hard reset the device again and had forgotten what the key sequence is. I had to jump online and dig up the answer, the first link I found described it precisely: How to hard reset the Sprint Mogul. I followed the instructions and was up and running again in about 5 minutes.

[Rant On]

Now the damnable thing about this phone, is that this needs to be done. I don’t know a single IPhone user out there that has had to do something similar. This is just freaking stupid. This is one more area were Microsoft really needs to tighten up their act and get something out the door that is vastly more stable, capable, feature rich, and above all has some seriously usable applications akin to the IPhone. Blackberries, strangely enough, are in the same boat with the IPhone. It appears that they have less issues altogether.

But I digress, I now have to go waste 30 minutes synching the damned phone.

[Rant Off]

Dammit! I Broke the Build!

I broke the build this morning as I fixed a bug at 1:12am. I didn’t just break it though, I broke it in an absolutely stupid, shameful, silly way. I somehow managed to stick a semi-colon on the end of a line of code before checking in, in addition to the semi-colon that was already on the end of the line of code. Woe is me, I’m a little special in the head today.

It does go to show though, technically, with modern tools I should not have been able to make that mistake. This is something I’ll have to work with others to assure we implement. Nobody, should be able to actually check in code that would cause a break of the build. I have a little research to do because in VSTS TFS 2008, the currently used tool, I’m not sure how to set this up. Hopefully I can help figure out a way to help implement this to reduce these wasted minutes and hours of each day for the teams.

In Other News

WebTrends has been getting some good news releases and other such things recently. Lately there has been a post about our new products and product efforts. WebTrends declared data independence. Beyond that if we take a look at what has been released we get into some interesting scenarios, especially for sites with serious traffic volumes that need measured! WebTrends Connect & Data Scheduler will provide multiple avenues for access to data, delivered on various frequencies you can setup and various methods in addition to that. Using Web Services, ODBC, and the associated APIs one can really wire up the data into dashboards and integrate the data into other tools. Imagine being able to actually tie in your analytics data for the executive team and display it beside the ad spot purchasing data, to compare web vs. TV purchased ads and follow through. I personally find it very gratifying to see an actual click through to purchase line versus and artificial “guesstimate” for TV ad purchases.

But just imagine, by connecting those systems it isn’t unfeasible to imagine even that data becoming available in some manner. I’ll leave that exercise (at least for now) up to the reader.

Open ID Rocks!

I mentioned a few days ago that Microsoft finally got on the band wagon, well Google has also decided last week that it will also provide Open ID Provider Services which I had not realized. But between both of them getting on board, that is awesome news.

…and more Broken Builds

As the day has moved on there have been other build breakages, not particularly me. However the onus has been put on me a few times. It makes me ponder what VSTS TFS is doing. I’ve used it in the past, mostly with VSTS TFS 2005, and have had tons of issues. I’m usually pretty observant of what source control systems do with my code, but TFS is super tricky. It ghosts things in and out, mixes up versioning and puts some files with other check ins, then reports a breakage on a CI build that has nothing to do with a particular check out.

Now last time I checked, that level of inaccuracy was unacceptable. I was hoping that these types of issues would have been resolved in 2008, but it looks like my hopes have been dashed. This doesn’t even touch on Ayende’s Issues that he’s mentioned in the past, and more, and I’m sure more. He just flat out states it flat out “ It means that it cannot be trusted”. Which honestly, I can’t disagree with. After using Subversion with TeamCity and other tools, TFS just does not have that same level of quality or trust. Once again I’ll state, I sure hope to see this fixed and changed in 2010, even though I’m not holding my breath this time, I still have a bruise from passing out for the 2008 version.