14 Dec '13, 10pm
DRY? YAGNI! Or will you?
The following three terms are often used in Agile. I appreciate that they have value, but I want to reiterate that they are heuristics, not panaceas. DRY Don’t Repeat Yourself. A lot of good intentions here, however, domain modeling is not that easy. Just because code looks the same, does not mean that implementations won’t change, especially across context boundaries. If you spend time DRYing up your code early, you don’t get to clearly observe divergence (and convergence). Repeat yourself until you’re confident (and perhaps dial down your confidence). It’s better to be late to the DRY party. Aim at being consistent, following clear patterns and precise domain oriented language. This will make it easier to discover emerging domain contexts and behaviors. Eventually you can DRY up your code, confident that you understand what it is you’re working with. YAGNI You Ain’t Gunn...