Comment by sejtnjir
7 years ago
Not every product is maintained for years. In many cases it's good to be able to choose between a quick solution and a good solution, as long as these are concious decisions and some record of accrued technical debt is kept.
Rarely if ever in the beginning of the project it's 100% sure or guaranteed how long the project will be maintained. There might be some estimates, but in the long run upper management might change their minds at any time and then you are fucked if you didn't build robust architecture from the start.
At least according to my experience and everyone I know in the industry.
But there are so many counterexamples to that too. I worked on a project following CI practices with a release every two weeks, and I can think of plenty of examples where we developed a feature, tested it with users, and scrapped it within a month. That team leaned toward strict practices, and we wasted so much time on code review and documentation of small details which only existed for a couple of weeks.
I also thing it is vastly overstated how difficult it is to incrementally refactor a project which is "fucked". It's always possible to break it into smaller pieces, and gradually improve the codebase until it is manageable and easy to work with.
I also thing it is vastly overstated how difficult it is to incrementally refactor a project which is "fucked". It's always possible to break it into smaller pieces, and gradually improve the codebase until it is manageable and easy to work with.
What if there's no automated testing worth a damn, and the penalty for a bug is very high? Been there, done that, and I have to say, you don't ever want to stay there!
The question is, if the project you worked would be a mess from the beginning, would it allow your company to test and scrap features fast?
Yes, it's possible, but at what cost? E.g. long hours, unhappy devs, implementation taking too long.
3 replies →
If you work on legacy code you can be sure that your code will be used for years if not decades.
Legacy code often ends up as such, because it was immediately available and immediately utilized. It worked then, and piled on functionality.
You don't see good looking legacy, because it didn't survive.
Often, the difference between a quick solution and a good solution isn't technical debt! (So long as there isn't an impediment to adding them in the future.) Missing features aren't technical debt.
Technical debt manifests in a code base, most generally as various forms of pain that occur when trying to add features. That's how the company "pays interest" on the technical debt. Coding so that you can always change your mind, however that is accomplished, is the key there. (This is one place where the "Law of Demeter" really shines!)
I think it's somewhat paradoxical: The software that gets delivered, produces value gets to live. The market prefers just-good-enough software