You were Yagni all over an you were asked to ExtendTheScope of the system. You feel compelled to write a DifferentVersionFromScratch. First make sure that now you have the right abstraction at hand. GetTheRightAbstraction this time. I'm not advocating GetTheRightAbstraction at the beginning of the project, because at that time it is hard to guess and easy to screw up. Consider it a risk and do the usual RiskAssessment and RiskMitigation: Ask the customer if he would like to ExtendTheScope in the future and let him know the alternatives. Now the risk is his, not yours. When the time comes to ExtendTheScope, simply write a DifferentVersionFromScratch. ---- When asked to ExtendTheScope you can either: * Create big and ugly patches (BigBallOfMud), or * Refactor to achieve ConceptualIntegrity, or * Rewrite a DifferentVersionFromScratch to achieve ConceptualIntegrity. When trying to achieve ConceptualIntegrity, make sure to GetTheRightAbstraction. -- GuillermoSchwarz ---- It is hard to GetTheRightAbstraction, but you know you have got the right abstraction when the abstraction stands the test of time. For example in computer networks the right abstraction is unique node numbers (like ip numbers), although we know that at the hardware level there are only signals and the most high level abstraction is the MacAddress. When you ftp, send mail or browse the web, you are connecting to differnet computers around the world, but that's just an abstraction, what really happens is that bytes are routed from your computer to the destination computer using several other computers, most of them are decided on the fly for each ip packet. ---- See ProgramsRepresentMentalModels, ProgrammingAsTheoryBuilding, SoftwareEngineeringIsCreative. See also YouArentGonnaNeedIt, DoTheSimplestThingThatCouldPossiblyWork, AllAbstractionsLie. ---- CategoryAbstraction