Summary
According to common wisdom, the best code is developed in-house. I am beginning to believe this is only true when the code must be tightly coupled, or there are realistic security concerns. These scenarios are less common than managers like to believe.
For run-of-the-mill development projects, outsourcing might have advantages above-and-beyond cost savings. If your code effort can be outsourced, you should try it. Not only will it be cheaper, but the final code will be easier to maintain.
Background
KSplice recently wrote about the best way to manage interns. The takehome point is: “Divide tasks to be as loosely-coupled as possible.”
Recently, a commentator on thefunded.com asked:
I’ve been working on a deal in which a larger software company would give me a platform they developed so we can build a business around it. The larger company has given up on it.
The key developer of the platform was to be included in the deal. But he’s apparently disgruntled and, literally, has gone postal. (There are serious issues; getting him back isn’t really an option now.)
So we have a platform, without documentation, and without the guy who built it. But it has been launched in public applications and is perfectly functional. Basically we would just be reskinning it and adding in a few new features when we relaunch under the new business.
My advice? Try outsourcing.
Try outsourcing
Here was my advice to this person:
Your goal is to improve the maintainability of your code, so that you can easily find new developers to jump in on your project. Your goal is also to have the code at a point that you are no longer beholden to any developers, and you can easily fire a developer without feeling like you are locked in to them.
My advice is that you find a good project manager to document the code and, more importantly, refactor the codebase to make the components more loosely coupled. This project manager should break the code into pieces and delegate to a handful of independent remote subcontractors who don’t communicate with each other. If independent remote workers can refactor and clean up the code, without communicating with each other, then it means the final code will be easy to maintain. It then follows that an in-house development team should be able to easily jump into the codebase. Or, you could outsource further improvments. Your choice.
Consider that the approach of independent remote developers with little communication is the same approach taken by many open-source projects.
If the project is hard to break into pieces, this is why you need a good project manager. He or she will understand the overall architecture, and see along what lines it is best to create division of responsibilities in the code.
You could choose a single tightly-knit dev team who are in constant communication, but the risk is that they will understand aspects of the code that they don’t document, and that there will be communal wisdom passed around by oral communication. In this case, you are bound to these developers.
What you want is everything written down and easy to pick up by the next guy. So you should force that to be the case in your refactoring process.
Although it might take independent remote developers more time to refactor the code-base than a single tightly-knit development team, if you go with the independent remote coders then the final product will be easier to maintain in the long run. And even though the independent remote coders will incur two or three times as many billable hours as the tightly knit team, if you use foreign programmers then their hourly rate is four to five times less than domestic programmers. So I think it’s a win in terms of cost and final results.
Even though I am a hardcore developer myself, I have recently been dabbling in subcontracting to independent developers in Eastern Europe, and have been amazed with the results. It allows me to develop much faster, and it makes my code easier to maintain, because it is impossible to subcontract work unless your code has good separation of concerns and is loosely coupled. I now have built some good relationships with sharp coders who I trust to understand my directions and deliver clean code on time.
I sense that I am going to get push back on this by defensive domestic coders, because it goes against the common wisdom, but I think it is an option worth considering.
Would you share your experiences, positive and negative, with outsourcing?

Nice point about how keeping communications written promotes documentation. Would be interesting to see how the project manager role scales up in a more complex project…
Sounds like you’ve found some good remote talent. Congrats, my outsourcing attempts have not been as successful.
As a “domestic coder” I’d be silly to oppose distributed development on principle, it’s obviously a proven approach in the open source world.
Talent is the key. Too many corporate executives mandate the use of offshore body shops, with negative impacts on quality and maintainability. Find the right talent, and they’ll get the job done no matter where they are.
It’s interesting to see someone who admits he uses outsourcing also to raise is software quality
congrats for you with your outsourcing partners.
I don’t see any relationship between outsourcing and code maintainability . It is really depend on who write the code and what is the domain.My outsourcing parter is one of the biggest outsourcing comp from India, CMMI level 5.
.
And the code is worst code that i ever seen, all copy paste. And it slow like shit. 3 times crash a day
I don’t think you can draw a conclusion by using your one time experience
In theory this seems like a great idea. I’m not opposed to outsource either except in terms of general contractors returning black boxes instead of code. My problem is that the idea a project manager could simply read the code and start breaking it up for refactoring seems exceptionally naïve. If they could do that then I suspect that code would already be reasonably easy to maintain already. Getting a high level overview of the entire code base is never easy. There are always small pieces hiding in the cracks that seemingly are not important, yet every character ends up being important when we’re talking about code. If you have a project manager that can do this sort of thing please ask him to blog about how he approaches reading a large code base (100k+ lines) and understanding it in such a way as to send off bits overseas or to a contractor for updates.
[…] The real problem with job hopping is the initial expensive startup cost to integrating a new employee into your organization. Job hopping would not really be so problematic if businesses (and new employees) were set up for people to contribute value immediately. Perhaps employers and employees alike would benefit from businesses restructuring their processes to be more modular and self-contained. This is similar to how it seems initially expensive to design your code so that components are loosely coupled, but ultimately this discipline leads to greater flexibility and easier maintainability. Similarly, structuring your organization and processes in such a way that you can easily add (or remove!) talent can ultimately lead to efficiency. (I make similar comments about outsourcing your code.) […]
I think that any industry can benefit from outsourcing. Like any business strategies, there are downsides as well, but I think that making wise choices can help you have a positive experience with outsourcing.
Bollocks!
Yes, loosely coupled code should be easier to maintain and then you could “fire unruly developers” at will.
Never seen this work (63 years old retired software engineer speaking).
You are only indirectly involved in software development, aren’t you?
BTW, this whole website doesn’t work in an Opera browser 10.10 (pages appear blank though their content is actually loaded) .
A little “software problem” may be?
http://github.com/turian
And your website doesn’t work on my browser either.
Huh?
Which website?
I didn’t left any though I have several, one of which is purposefully Firefox only (no time to waste with MicroShit).
The one in the suffix of yr email address. I’m on Firefox 3.6.6 now.
I looked at this site under browsershots.org, but I don’t see an issue under Opera 10. Feel free to send me a screenshot of the error on your end.
BTW, I don’t have much experience coding on big teams. My coding experience is mainly solo. So you might be right that outsourcing is ineffective for big-team style coding, which I can’t really comment on.
Yes, it is an option worth considering… if you don’t give a damn about the creativity and innovation that can be generated when your developers actually talk with each other, bounce ideas off of each other, and collaborate in the creative process of software development.
As for cutting costs by going with lower-income coders, here’s an idea I think you’ll love: adopt children from other countries, lock them away in your attic, train them to be programmers, then pay them in bread and water. Think of the profits!
If you’re worried about your code base being properly documented, then give its developers a mandate to do so, and make that documentation a part of their expected duties. If you want loosely coupled components, then have the project manager set that expectation, and confirm that need has been met.
Your solution… cheap labor done by people who don’t talk to each other… is the sort of solution that might appeal to an accountant, but not to someone who actually knows something about writing good code… and I’ve been writing code for 32 years and counting, so I think I know something about the subject.