Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

The plugin computes and feds Sonar with four (45) new metrics : Authors Activity, Commits / UserAuthor, Commits / Clock Hour, Commits / Week Day and Commits / Month.
Four project widgets ( under the SCM category ) display these metrics using graphical representations.

Info

The "commits per user author widget" displays only the top commiters 10 authors ( list and pie chart )

 

The "Author activity" widget displays a stacked 3D bar chart about authors activities types : New files(green), modifications(blue) , deletions(red)

Image Added 

The other three widgets display in a bar chart the number of commits / clock hour, week day or month.

...

  1. Install the SCM Stats plugin through the Update Center or download it into the SONAR_HOME/extensions/plugins directory
  2. If you plan to use this plugin with non-maven projects, or SCM access is avalable only with username/password or no SCM information is included in project's pom.xml you have to also install the SCM Activity plugin 
  3. Restart the Sonar server
  4. Set the SCM URL of your project (see SCM URL Format) by setting the sonar.scm.url property of SCM Activity plugin. For Maven projects this is automatically discovered if it's already set in pom.xml

  5. Set the SCM user / password (if needed) by setting the sonarc.scm.user.secured and sonar.scm.password.secured properties of SCM Activity plugin
  6. Launch a new quality analysis and the metrics will be fed

Grabbing stats for multiple periods

Since 0.2 the plugin allows the collection of SCM stats for multiple (1-3) periods. By default the plugin collects stats for the whole history ( sonar.scm-stats.period1 = 0 days ).
You can have different periods on a global or project level by setting the number of days prior to the current date that the plugin will collect scm stats.

For example to collect scm stats for the last month, enter a value of 30, for the last week a value of 7 etc.

The properties for period 2 ( sonar.scm-stats.period2 and period 3 ( sonar.scm-stats.period3 can have the value of zero(0) but the plugin will ignore it. In other words, whole history stats, will be collected only if sonar.scm-stats.period1 property is set to zero(0). Negative values are ignored for all periods.

Compatibility Matrix

Plugin version

0.10.2
Source Control  

Subversion

(tick)

(tick)
Git(tick)(tick)
Mercurial(error)(tick)

Metrics Definitions

Name

Key

Qualitative

Description

Commits Per UserAuthor

scm-commits-per-user

no

Reports on the number of commits per userauthor.

Commits Per Clock Hour

scm-commits-per-clockhour

no

Reports on the number of commits per clock hour.

Commits Per Week Dayscm-commits-per-weekdaynoReports on the number of commits per week day.
Commits Per Monthscm-commits-per-monthnoReports on the number of commits per month.

...

JIRA Issues
anonymoustrue
titleRelease 0.2
height320
width900
columnstype;key;summary;priority
urlhttp://jira.codehaus.org/sr/jira.issueviews:searchrequest-xml/temp/SearchRequest.xml?fixfor=18847&pid=11911&sorter/field=priority&sorter/order=DESC&tempMax=1000

JIRA Issues
anonymoustrue
titleRelease 0.1
height320
width900
columnstype;key;summary;priority
urlhttp://jira.codehaus.org/sr/jira.issueviews:searchrequest-xml/temp/SearchRequest.xml?fixfor=18774&pid=11911&sorter/field=priority&sorter/order=DESC&tempMax=1000