Duplicate to decouple

From WikiContent

Revision as of 12:17, 15 October 2008 by Kevlin (Talk | contribs)
(diff) ←Older revision | Current revision (diff) | Newer revision→ (diff)
Jump to: navigation, search

Often it is more valuable to proceed independently, not being forced to wait for others or to discuss with anybody.

This is a key argument to avoid common code portions. Shared code implies an outside resistance against changes.

While reuse is considered a great concept, in daily life it hurts. At too small a scale it is an obstacle rather than a support. Go for reuse at a large scale, reuse components that would take you much (much!) longer to rewrite than to reuse.

If it is a quick thing, just do it again, yourself in control.

However, mind this:

  • Don't repeat yourself
  • Implicit coupling is also coupling

One day you'll find that you have to synch with all the other code portions that you just got rid of by your duplication. While you got rid of your in-progress dependency, it is still there on a larger scale.

So do yourself a favour and keep track of your duplications. I like the idea of a debt board for this.

Duplications: they are worth doing, and they are worth remembering.

Personal tools