Description / Features
This plugin is an implementation of the Software Improvement Group (SIG) Maintainability Model.
The model is a 2 steps approach: calculate base indicators and then combine them to get higher level ones.
Every indicator results to a 5-levels ranking from -- (very bad)to ++ (very good).
The first step is to evaluate base metrics.
Volume: based on the number of lines of code
Rank | LOC |
|---|---|
-- | > 1310000 |
- | > 655000 |
0 | > 246000 |
+ | > 66000 |
++ | > 0 |
Duplications: based on the density of duplications
Rank | Duplication |
|---|---|
-- | > 20% |
- | > 10% |
0 | > 5% |
+ | > 3% |
++ | > 0% |
Unit tests: based on the coverage of the application by unit tests
Rank | Coverage |
|---|---|
++ | > 95% |
+ | > 80% |
0 | > 60% |
- | > 20% |
-- | > 0% |
Complexity: based on the cyclomatic complexity of methods
A first pass consists in determining the percentage of LOC belonging to methods that are in a certain range of complexity
Eval | Complexity |
|---|---|
Very high | > 50 |
High | > 20 |
Medium | > 10 |
Low | > 0 |
Then based on the distribution, we use the following table to evaluate the rank :
Rank | Medium | High | Very High |
|---|---|---|---|
++ | < 25% | < 0% | < 0% |
+ | < 30% | < 5% | < 0% |
0 | < 40% | < 10% | < 0% |
- | < 50% | < 15% | < 5% |
Rank is -- otherwise
Unit size: based on the lines of code of methods
A first pass consists in determining the percentage of LOC belonging to methods that are in a certain range of LOCS
Eval | LOCs |
|---|---|
Very high | > 100 |
High | > 50 |
Medium | > 10 |
Low | > 0 |
Then based on the distribution, we use the following table to evaluate the rank :
Rank | Medium | High | Very High |
|---|---|---|---|
++ | < 25% | < 0% | < 0% |
+ | < 30% | < 5% | < 0% |
0 | < 40% | < 10% | < 0% |
- | < 50% | < 15% | < 5% |
Rank is -- otherwise
The second step is to combine them, by doing a simple average, using the following mapping table :
| Volume | Complexity | Duplications | Unit size | Unit tests |
|---|---|---|---|---|---|
analysability |
|
|
|
|
|
changeability |
|
|
|
|
|
stability |
|
|
|
|
|
testability |
|
|
|
|
|
and therefore obtain 4 advanced indicators representing the 4 axes of maintainability of a software.
Optionally, the 4 indicators can be combined by doing a simple average to give the maintainability ranking.

It is to be noted that the color of the spider represents the actual combined value, from RED = -- to GREEN = ++
Installation
- Install the plugin through the Update Center or download it into the SONARQUBE_HOME/extensions/plugins directory
- Restart the SonarQube server
Usage
Run a new quality analysis and the metrics will be fed.
Change Log
| Version 1.0.1 (1 issues) | |||
|---|---|---|---|
| Type | Key | Summary | Priority |
|
|
SONARPLUGINS-971 | Remove usage of SquidSearch |
|
| Version 1.0 (1 issues) | |||
|---|---|---|---|
| Type | Key | Summary | Priority |
|
|
SONARPLUGINS-769 | Use sonar-plugin packaging |
|
| Version 0.3.1 (1 issues) | |||
|---|---|---|---|
| Type | Key | Summary | Priority |
|
|
SONARPLUGINS-445 | Make metric consolidate at views level |
|

