How to Measure Technical Debt and How to Keep Track of the Progress
Sometimes the pressure to deliver fast results leads to coding shortcuts. What does it have in common with the technical debt?
Join the DZone community and get the full member experience.Join For Free
Nothing in this world is perfect. Neither is code. Sometimes the pressure to deliver fast results leads to coding shortcuts. Sometimes developers can’t find the right solution immediately and sometimes they are too lazy to do that. One day they misread the requirements, and the other – the requirements are changed in the process. But what does it have in common with the technical debt?
You may also like: Technical Debt: What It Is, Why It's Important, and How to Prioritize It
What Is Tech Debt?
The term “technical debt” was first introduced by an American agile activist Ward Cunningham in 1992. Tech debt is a metaphor that describes the consequences of immature code. We can say that tech debt appears when developers — consciously or unconsciously — make imperfect decisions. This can lead to extra work in the future that results in an additional cost for the company. In other words, when those decisions are made you take a “technical loan” and will have to pay the interest later.
According to the Agile Alliance, bugs, errors, and duplication in platform architecture are just some examples of failures that can cause tech debt. Each of them and especially their combination will have a negative impact on the company’s productivity and profitability. Therefore, it is definitely not enough to know that tech debt exists, it is necessary to measure technical debt and understand how to deal with it.
How to Measure Tech Debt?
Properly managed, technical debt is safe. Moreover, it allows to deliver valuable products faster and helps your business grow. On the contrary, gone-rabid-technical-debt can paralyze your projects and turn into big trouble for your company. Luckily there are ways to keep it under control.
Develop Agile Approach to Tech Debt
The first step of keeping tech debt under control is the ability to create a proper attitude towards it. Your team should be aware of technical debt and be ready to make their contribution to minimizing its negative consequences. The developers should be responsive and report the technical debt on a regular basis. The team leader for its part must be ready to invest its time and effort into managing technical debt and take actions if needed.
Watch Your Technical Debt
According to the survey conducted by the Chalmers University of Technology, the University of Oslo, and the Research Team Barcelona, backlogs and static analyzers allow decreasing the management overhead by 7%. Technical debt can be also maintained in a backlog of a tracker system such as JIRA. It is strongly discouraged to create a separate backlog for technical debt. If your tech debt issues are on the same sheet as all tasks — you have no chance to forget about it.
Use Tools or How to Calculate Technical Debt
There are numerous tools that help to measure and track tech debt. Technical debt calculation is based on different technical debt metrics such as code complexity, code duplication, test coverage, coding rules violations and lack of documentation.
“We suggest using an automated tool to gather code issues that are then translated into hours of work which in turn are translated into additional costs.”
— Alex Gostev, Project Portfolio Manager at QArea
Another useful set of tools are linters, that are technology-specific, Dmitriy Barbashov, the Chief Technology Officer at QArea adds.
QArea created its own easy-to-use tool for measuring tech debt dynamics — Code Quality. Our developers also built DueRank – a global code quality ranking aimed at making code quality transparent and countable.
There is one more method for measuring technical debt — through experiments.
“Properly set up an experiment within the company linking refactoring work with positive dynamics in metrics that can be translated into numbers — fewer hours of work for maintaining code base, less re-appearing bugs, a higher amount of customer complaints resolved.”
— Dmitriy Barbashov
Published at DZone with permission of Anna Smith. See the original article here.
Opinions expressed by DZone contributors are their own.