Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 34 Next »


Technical Debt Plugin


Freddy Mallet, Olivier Gaudin


Most Recent Version






Latest stable : technical-debt-0.2.jar
Called for a vote : technical-debt-0.3-SNAPSHOT.jar

Compatibility with Sonar

Plugin versions










Description / Features

The Technical Debt plugin is an unified metric combining quality axes (Duplication, Violations, Complexity, Coverage, Documentation).

The basic principle is to calculate how much it would cost to clean all defects from every axis (no violation, no duplication...) : that means reimbursing the Technical Debt. 

The plugin contains 4 indicators :

  • The cost of the debt in $$
  • The cost of the debt in man days
  • The debt ratio (%)
  • The repartition of the debt across the axis

A note indicates at the bottom of repartition if coverage measure was not available (light projects).

Objectives of the plugin

  • give helicopter view on the global quality of a project
  • compare projects
  • understand where the cost to improve lies
  • communication tool with outside to explain why quality improvement is required

How all this gets calculated

Full details of calculation are available here.

The debt ratio

The debt ratio enables to compare projects. Indeed having $ 10,000 debt on a "small" project does not mean the same as the same debt on a big project. The debt ratio consists in comparing the actual debt with the total possible debt for the project (the project has got 100% lines duplicated, 0% coverage...)

Drill down

Clicking on the debt brings to the usual drill down page showing modules / packages / classes most impacted


Most of the settings / default values can be configured by going to Configuration -> Settings -> Technical Debt.

Usage & Installation

  1. Copy the jar into /extensions/plugins/ directory
  2. Restart Sonar Web server
  3. Launch a new quality analysis and the technical debt metrics will be fed

Known limitations

A significant improvement to the would be to gather manual measures : see SONARPLUGINS-91. Indeed this would enable to record other technical debts that are not gathered by Sonar to get a complete view.

Having a real cost to resolve for each rule would add a lot accuracy


Technical Debt 0.3 :


Technical Debt 0.2 :


  • No labels