Todays’ Problem are Yesterdays’ Solution
Recently I heard someone say, "Todays' problems are yesterdays' solutions". I really wish I could remember who it was, so that I can credit them but nevertheless it resonated with me especially in the context of software development. This succinctly summed up some of the notion I have about solution design.
If Todays' problem are yesterdays' solutions, it stands to reason to think tomorrows' problems will be caused by todays' solutions. If the solutions' are becoming incidental complexities over time and we will inevitably face accidental complexities and potentially essential complexities when dealing with future problems. Then how are we ever going to stay above all these problems?
Three ways I approach this are,
1. Build a highly decomposed systems. That way you can replace parts of the solution that would or could become problematic and replace it with generic solution pattern/tool potentially created by someone else. Define clear purpose for parts of your systems with DDD as your guide.
2. Expect your system to evolve and treat everything as if it's in a perpetual state of evolution.
3. Solve a class of problem rather than one single instance of a problem. In other words, use or come up with patterns; understand the core of your problem; abstract your solution as much as possible. This way you can reuse or apply the same solution to similar problems.
These options are neither exhaustive nor mutually exclusive.
Stay away from the one solution for one problem approach as much as possible. There are always exceptions and there are also trade-offs. Don't underestimate the maintainability of a particular solution while evaluating it.