The Blog
Strangling legacy code
published November 30, 2009
How do you refactor a legacy module which is used by many clients? Well, you strangle it. In a picture below we have two clients using some legacy code that we want to get rid of.

You start by creating a new interface and switching part of the usage to that interface.

Gradually, you refactor parts of your legacy code and move more clients using the new implementation.

In some point, you have managed to move all usage from the legacy interfaces to the new implementation, but you still might be using the legacy implementation under the hood.

The final step is to completely remove legacy code once you got all your necessary features refactored.

And actually delete all your legacy code, I do not want to see huge code blocks commented out “just in case we need this in the future”. You don’t. And if you do, you still find it in your SVN, right?
No Comments to Strangling legacy code


Subscribe to RSS feed
The Tag Cloud
Agile Business Coaching Coding horror Conference Customer Design of Experiments Future Group dynamics ITIL It should not be that hard Java EE Kanban Leadership Lean Liferay Methodologies Natural UI Performance tuning Process Productivity Quality Retrospective RIA Scrum Six Sigma Social psychology Software Software architecture Testing This is great TOGAF
WP Cumulus Flash tag cloud by Roy Tanck and Luke Morton requires Flash Player 9 or better.
Samuli's Links
The Blog Archive
January 2013 (1)
February 2012 (1)
January 2012 (1)
November 2011 (1)
June 2011 (2)
May 2011 (1)
April 2011 (2)
March 2011 (2)
February 2011 (1)
January 2011 (1)
December 2010 (1)
November 2010 (1)
October 2010 (3)
September 2010 (3)
August 2010 (5)
July 2010 (2)
June 2010 (3)
May 2010 (4)
April 2010 (2)
March 2010 (6)
February 2010 (7)
January 2010 (3)
December 2009 (7)
November 2009 (6)
