<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet href="http://feeds.feedburner.com/~d/styles/rss2full.xsl" type="text/xsl" media="screen"?><?xml-stylesheet href="http://feeds.feedburner.com/~d/styles/itemcontent.css" type="text/css" media="screen"?><rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0" version="2.0">

<channel>
	<title>Sonar</title>
	
	<link>http://sonar.codehaus.org</link>
	<description>Embrace quality</description>
	<pubDate>Thu, 04 Dec 2008 07:44:31 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.5.1</generator>
	<language>en</language>
			<atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="self" href="http://feeds.feedburner.com/Sonar" type="application/rss+xml" /><feedburner:emailServiceId>2531086</feedburner:emailServiceId><feedburner:feedburnerHostname>http://www.feedburner.com</feedburner:feedburnerHostname><item>
		<title>Tendencies in Sonar</title>
		<link>http://feeds.feedburner.com/~r/Sonar/~3/473439415/</link>
		<comments>http://sonar.codehaus.org/tendencies-in-sonar/#comments</comments>
		<pubDate>Wed, 03 Dec 2008 09:48:49 +0000</pubDate>
		<dc:creator>Olivier Gaudin</dc:creator>
		
		<category><![CDATA[blog]]></category>

		<category><![CDATA[functionality]]></category>

		<guid isPermaLink="false">http://sonar.codehaus.org/?p=199</guid>
		<description><![CDATA[One of the very good feature in Sonar is the tendencies. The tendencies are visible in every screen, from portfolio [...]]]></description>
			<content:encoded><![CDATA[One of the very good feature in Sonar is the tendencies. The tendencies are visible in every screen, from portfolio to class view, and are materialized by little arrows next to each measure. Those arrows show the trend for the measure. 
<br/>
This blog entry intends to explain how to read them, how Sonar makes their calculation and how they can be used.
<br/><br/>
Sonar uses 5 levels to describe the tendency of a measure. Each level is represented by an arrow : 
<br/><br/>
<table>
   <tr height="23px" >
      <td>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</td>
      <td style="border-bottom: 1px solid;"><img style="padding:0;" src="http://nemo.sonar.codehaus.org/images/tendency/2-black.png" alt="" />&nbsp;&nbsp;</td>
      <td style="border-bottom: 1px solid; border-left: 1px solid; padding-left:7px">Strong increase</td>
   </tr>
   <tr height="23px">
      <td>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</td>
      <td style="border-bottom: 1px solid;"><img style="padding:0;" src="http://nemo.sonar.codehaus.org/images/tendency/1-black.png" alt="" />&nbsp;&nbsp;</td>
      <td style="border-bottom: 1px solid; border-left: 1px solid; padding-left:7px">Medium increase</td>
   </tr>
   <tr height="23px">
      <td>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</td>
      <td style="border-bottom: 1px solid;">&nbsp;</td>
      <td style="border-bottom: 1px solid; border-left: 1px solid; padding-left:7px">Neutral</td>
   </tr>
   <tr height="23px">
      <td>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</td>
      <td style="border-bottom: 1px solid;"><img style="padding:0;" src="http://nemo.sonar.codehaus.org/images/tendency/-1-black.png" alt="" />&nbsp;&nbsp;</td>
      <td style="border-bottom: 1px solid; border-left: 1px solid; padding-left:7px">Medium decrease</td>
   </tr>
   <tr height="23px">
      <td>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</td>
      <td><img style="padding:0;" src="http://nemo.sonar.codehaus.org/images/tendency/-2-black.png" alt="" />&nbsp;&nbsp;</td>
      <td  style="border-left: 1px solid; padding-left:7px">Strong decrease</td>
   </tr>
</table>
<br/>
Sonar uses black(<img style="padding:0;vertical-align: middle" src="http://nemo.sonar.codehaus.org/images/tendency/1-black.png" alt="" />) arrows to represent tendencies on the quantitative metrics (the ones that are not reflecting quality of the code, for example number of lines of code).
<br/><br/>
Sonar uses red(<img style="padding:0;vertical-align: middle;" src="http://nemo.sonar.codehaus.org/images/tendency/1-red.png" alt="" />) or green(<img style="padding:0;vertical-align: middle;" src="http://nemo.sonar.codehaus.org/images/tendency/1-green.png" alt="" />) arrows to represent tendencies on the qualitative metrics (the ones that are reflecting quality of the code, for example code coverage). The red is used when the quality decreases, the green when it increases.
<br/><br/>
Of course, it is to be noted that if the percentage of duplicated lines decreases it will be represented by <img style="padding:0;vertical-align: middle" src="http://nemo.sonar.codehaus.org/images/tendency/-2-green.png" alt="" /> because it is considered as an improvement.
<br/><br/>
In order to display the tendencies, we decided that making a simple difference between the last two measures of each metrics was not accurate enough. Therefore we implemented a more advanced algorithm : the least squares method. The least squares is a linear regression analysis that helps removing the noise in order to determine a trend on discrete measures. 
In other words, Sonar takes the last X measures, checks that the set of measures make some sens (by testing the correlation rate), determines an estimated slope and displays it using the arrows.
<br/><br/>
Since Sonar uses the last X snapshots, you would expect this X is configurable: that is the case ! Simply sign in, go to preferences -> measures menu. The number of days there is not really a number of days, but in fact a number of snapshots that are going to be used. You can increase this number as much as you like, as long as you have enough snapshots in you database !
<br/><br/>
Where do we get from there? If you take measure at a regular frequency, it means that you are able to get weekly, monthly tendencies, ... on all your pages within Sonar.

<img src="http://feeds.feedburner.com/~r/Sonar/~4/473439415" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://sonar.codehaus.org/tendencies-in-sonar/feed/</wfw:commentRss>
		<feedburner:origLink>http://sonar.codehaus.org/tendencies-in-sonar/</feedburner:origLink></item>
		<item>
		<title>Sonar light: the low-calorie mode for Sonar</title>
		<link>http://feeds.feedburner.com/~r/Sonar/~3/464851060/</link>
		<comments>http://sonar.codehaus.org/sonar-light-the-low-calorie-mode-for-sonar/#comments</comments>
		<pubDate>Tue, 25 Nov 2008 09:48:15 +0000</pubDate>
		<dc:creator>Olivier Gaudin</dc:creator>
		
		<category><![CDATA[blog]]></category>

		<category><![CDATA[functionality]]></category>

		<guid isPermaLink="false">http://sonar.codehaus.org/?p=191</guid>
		<description><![CDATA[When I initially wrote this blog entry, I chose a much more original title : &#8220;What is the analogy between [...]]]></description>
			<content:encoded><![CDATA[When I initially wrote this blog entry, I chose a much more original title : <em>"What is the analogy between a Coke light and Sonar light"</em>. But then I realized that "Coca Light" (the French for Diet Coke) does not translate to "Coke light"... The title was not as attractive anymore : I had to back up ! ;-)
<br/><br/>
As any good code analysis tool, Sonar performs static as well as dynamic analysis (code coverage by unit tests). The dynamic analysis requires a lot of processing power (calories burning) since the unit components of the program must be compiled before they can be executed. On the contrary, static analysis just needs to analyze source code in order to calculate metrics like cyclomatic complexity or to detect bad coding practices.<span id="more-191"></span>
<br/><br/>
Further more, the dynamic analysis in Sonar requires that the project is <a href="http://maven.apache.org">"mavenized"</a> in order to have a list of runtime dependencies. Since there are still a few projects around that are not mavenized yet, the demand was growing for <b>a way of using Sonar on those projects</b>.
<br/><br/>
Those two reasons were good enough to create Sonar light, a mode without dynamic analysis and that does not require your project runs under maven.
A live example of Sonar light is the <a href="http://nemo.sonar.codehaus.org/project/dashboard/50544">Tomcat project in Nemo</a>.
<br/><br/>
Practically, in order to run analysis on a project in the light mode, you only need the simplest possible pom.xml placed in the root of your project : <br/><br/>
<code><font size="-2">
&lt;project&nbsp;xmlns="http://maven.apache.org/POM/4.0.0"&nbsp;xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"&nbsp;xsi:schemaLocation="http://maven.apache.org/POM/4.0.0&nbsp;http://maven.apache.org/xsd/maven-4.0.0.xsd"&gt;<br/>
&nbsp;&nbsp;&lt;modelVersion&gt;4.0.0&lt;/modelVersion&gt;<br/>
&nbsp;&nbsp;&lt;groupId&gt;[GROUPID]&lt;/groupId&gt;<br/>
&nbsp;&nbsp;&lt;artifactId&gt;[ARTIFACTID]&lt;/artifactId&gt;<br/>
&nbsp;&nbsp;&lt;name&gt;[PROJECT&nbsp;NAME]&lt;/name&gt;<br/>
&nbsp;&nbsp;&lt;version&gt;[PROJECT&nbsp;VERSION]&lt;/version&gt;<br/>
&nbsp;&nbsp;&lt;build&gt;<br/>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&lt;sourceDirectory&gt;[SOURCE&nbsp;DIRECTORY]&lt;/sourceDirectory&gt;<br/>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&lt;plugins&gt;<br/>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&lt;plugin&gt;<br/>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&lt;groupId&gt;org.apache.maven.plugins&lt;/groupId&gt;<br/>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&lt;artifactId&gt;maven-compiler-plugin&lt;/artifactId&gt;<br/>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&lt;configuration&gt;<br/>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&lt;source&gt;1.5&lt;/source&gt;<br/>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&lt;target&gt;1.5&lt;/target&gt;<br/>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&lt;/configuration&gt;<br/>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&lt;/plugin&gt;<br/>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&lt;/plugins&gt;<br/>
&nbsp;&nbsp;&lt;/build&gt;<br/>
&nbsp;&nbsp;&lt;properties&gt;<br/>
&nbsp;&nbsp;&nbsp;&nbsp;<b>&lt;sonar.light&gt;true&lt;/sonar.light&gt;</b><br/>
&nbsp;&nbsp;&lt;/properties&gt;<br/>
&lt;/project&gt;<br/>
</font></code><br/>
Launch Sonar Maven goal <code><font size="-1">mvn org.codehaus.sonar:sonar-maven-goal:1.X:sonar</font></code> and go to the <a href="http://nemo.sonar.codehaus.org">Sonar web interface</a> to see the results.
<br/><br/>
Coming back to the initial title : <b>in both cases you are using a low-calorie product.</b>
<br/>





<img src="http://feeds.feedburner.com/~r/Sonar/~4/464851060" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://sonar.codehaus.org/sonar-light-the-low-calorie-mode-for-sonar/feed/</wfw:commentRss>
		<feedburner:origLink>http://sonar.codehaus.org/sonar-light-the-low-calorie-mode-for-sonar/</feedburner:origLink></item>
		<item>
		<title>Eclipse, Checkstyle, Sonar : an emerging source code management solution</title>
		<link>http://feeds.feedburner.com/~r/Sonar/~3/458366932/</link>
		<comments>http://sonar.codehaus.org/eclipse-checkstyle-sonar-an-emerging-source-code-management-solution/#comments</comments>
		<pubDate>Wed, 19 Nov 2008 13:05:56 +0000</pubDate>
		<dc:creator>Freddy Mallet</dc:creator>
		
		<category><![CDATA[blog]]></category>

		<guid isPermaLink="false">http://sonar.codehaus.org/?p=194</guid>
		<description><![CDATA[We'll progressively communicate on this fully Open Source integrated solution but for today, here are the first three components [...]]]></description>
			<content:encoded><![CDATA[Having a tool like Sonar to monitor source code and continuously evaluate risks is a good start. Nevertheless, Sonar should not only  be considered as a passive audit tool that can quickly help you scan your projects portfolio.

<br/><br/>

Sonar is the missing piece of a global source code management solution. We'll progressively communicate on this fully Open Source integrated solution but for today, here are the first three components :
<ul>
	<li><a href="http://www.eclipse.org/ganymede/">Eclipse Ganymede</a></li>
	<li><a href="http://eclipse-cs.sourceforge.net/">Eclipse Checkstyle plugin eclipse-cs</a></li>
	<li><a href="http://sonar.codehaus.org/downloads/">Sonar 1.4.3</a></li>
</ul>
<span id="more-194"></span>

<br/>
A good source code management solution should not only provide a way of being reactive through a regular reporting but as well to be proactive by enabling the developer to integrate quality in the heart of the development process. In others words, each developer should be able to check the quality of a newly or updated source code before publishing it to a source control system like Subversion or CVS.

<br/><br/>

Let's take the example of <a href="http://checkstyle.sourceforge.net/">Checkstyle</a> quality rules for today. We'll see later how to generalize this approach to <a href="http://www.junit.org/">JUnit</a>, <a href="http://www.atlassian.com/software/clover/">Clover</a>, <a href="http://pmd.sourceforge.net/">PMD</a>...
<br/><br/>

<a href="http://nemo.sonar.codehaus.org/rules_configuration/index/3">Sonar web interface</a> allows you to quickly define and activate a quality rules profile :

<a href="http://sonar.codehaus.org/wp-content/uploads/2008/11/rules_profiles.jpg"><img class="aligncenter size-medium wp-image-195" title="rules_profiles" src="http://sonar.codehaus.org/wp-content/uploads/2008/11/rules_profiles.jpg" alt="" width="600" height="74" /></a>
Without any more configuration, each time you scan a project with Sonar, this rules profile is automatically applied on source code. On the previous screenshot, you can notice that Sonar provides on each rules profile a permalink (URL) to get the checkstyle configuration file associated with this profile.

<br/><br/>

As a developer, in order to apply the exact same rules before publishing any new modifications on source code, you simply need to:
<ul>
	<li>Use the well known eclipse IDE with the eclipse-cs plugin.</li>
	<li>Go to Eclipse -&gt; Preferences -&gt; Checkstyle menu</li>
	<li>Create a new Global Check Configuration, choose the "Remote Configuration" type and copy/paste the permalink provided by Sonar, for example <a href="http://nemo.sonar.codehaus.org/rules_configuration/export/java/Sonar%2520way/checkstyle.xml">http://nemo.sonar.codehaus.org/rules_configuration/export/java/Sonar%2520way/checkstyle.xml</a></li>
</ul>
<a href="http://sonar.codehaus.org/wp-content/uploads/2008/11/check_configuration.jpg"><img class="aligncenter size-medium wp-image-196" title="check_configuration" src="http://sonar.codehaus.org/wp-content/uploads/2008/11/check_configuration.jpg" alt="" width="300" height="174" /></a>
<br/>
<ul>
	<li>Right Click on any eclipse project you want to analyze and select Checkstyle -&gt; Activate Checkstyle</li>
</ul>
<br/>
<b>No more to do !</b>

<br/><br/>

Every time you make some change to your code, the eclipse "Problems" view tells you what are the quality rules violations in your source code. Of course, those problems are exactly the same ones Sonar reports.

<br/>

<a href="http://sonar.codehaus.org/wp-content/uploads/2008/11/checkstyle_result.jpg"><img class="aligncenter size-full wp-image-197" title="checkstyle_result" src="http://sonar.codehaus.org/wp-content/uploads/2008/11/checkstyle_result.jpg" alt="" width="500" height="141" /></a>

<br/>
That's enough to begin with. If you want to know more about the power of the Eclipse Checkstyle plugin, you can have a look at the <a href="http://eclipse-cs.sourceforge.net/">eclipse-cs web site</a>.<img src="http://feeds.feedburner.com/~r/Sonar/~4/458366932" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://sonar.codehaus.org/eclipse-checkstyle-sonar-an-emerging-source-code-management-solution/feed/</wfw:commentRss>
		<feedburner:origLink>http://sonar.codehaus.org/eclipse-checkstyle-sonar-an-emerging-source-code-management-solution/</feedburner:origLink></item>
		<item>
		<title>SonarSource, a spin-off dedicated to Sonar development</title>
		<link>http://feeds.feedburner.com/~r/Sonar/~3/453424105/</link>
		<comments>http://sonar.codehaus.org/sonarsource-a-spin-off-dedicated-to-sonar-development/#comments</comments>
		<pubDate>Tue, 11 Nov 2008 18:16:18 +0000</pubDate>
		<dc:creator>Sonar team</dc:creator>
		
		<category><![CDATA[blog]]></category>

		<category><![CDATA[sonarsource]]></category>

		<guid isPermaLink="false">http://sonar.codehaus.org/?p=187</guid>
		<description><![CDATA[We are happy and proud to announce the launch of a new company : SonarSource.]]></description>
			<content:encoded><![CDATA[<br/><br/>
<center><b>We are happy and proud to announce the launch of a new company</b>
<br/><br/><img width="200px" src="http://sonar.codehaus.org/wp-content/uploads/2008/11/sonarsource-300x94.png" alt="SonarSource" /></center><br/>
Given Sonar's success, we have decided to create a spin-off of <a href="http://www.hortis.ch/">Hortis</a>, dedicated to the development and support of the product : it just happened today !<span id="more-187"></span>
<br/>
The newly formed company has got a highly motivated team made of :
<ul>
	<li><a href="http://www.linkedin.com/in/freddymallet">Freddy Mallet</a></li>
	<li><a href="http://www.linkedin.com/in/simonbrandhof">Simon Brandhof</a></li>
	<li><a href="http://www.linkedin.com/pub/2/303/916">Cédric Munger</a></li>
	<li><a href="http://www.linkedin.com/in/oliviergaudin">Olivier Gaudin</a></li>
</ul>

<br/>
SonarSource's ultimate objective is to carry on Sonar's development to make it an open source enterprise tool widely adopted in the software development world.
<img src="http://feeds.feedburner.com/~r/Sonar/~4/453424105" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://sonar.codehaus.org/sonarsource-a-spin-off-dedicated-to-sonar-development/feed/</wfw:commentRss>
		<feedburner:origLink>http://sonar.codehaus.org/sonarsource-a-spin-off-dedicated-to-sonar-development/</feedburner:origLink></item>
		<item>
		<title>Using the ‘Reviews’ section on the project dashboard</title>
		<link>http://feeds.feedburner.com/~r/Sonar/~3/453424106/</link>
		<comments>http://sonar.codehaus.org/using-the-reviews-section-on-the-project-dashboard/#comments</comments>
		<pubDate>Tue, 04 Nov 2008 17:33:27 +0000</pubDate>
		<dc:creator>Freddy Mallet</dc:creator>
		
		<category><![CDATA[blog]]></category>

		<category><![CDATA[functionality]]></category>

		<guid isPermaLink="false">http://sonar.codehaus.org/?p=173</guid>
		<description><![CDATA[You might have already paid attention to this little and empty section named &#8220;Reviews&#8221; at the bottom right of any [...]]]></description>
			<content:encoded><![CDATA[You might have already paid attention to this little and empty section named "Reviews" at the bottom right of any project dashboard, but what is this section about ?
<br/>
<img src="http://sonar.codehaus.org/wp-content/uploads/2008/11/blank_reviews.jpg" alt="" title="blank_reviews" width="500" height="69" class="aligncenter size-full wp-image-180" />

<br/><br/>
Originally, this functionality was developped for one of our customer : this company has a quality assurance team in charge of regularly interviewing members of development teams on different areas like "Configuration Management", "Project Planning", "Technical Design", etc. They already used Sonar to check and follow code quality on their projects portfolio and wanted to feed Sonar with the results of those reviews. 
<br/><br/>In Sonar 1.5 we've extended this to any kind of metrics which could be fed manually like "Team size", "Business Value", ... But let's go back to Sonar 1.4.X and the way this functionality can currently be used.
<span id="more-173"></span>
<br/><br/>
The first thing is to log into Sonar with the administrator account. If you go back to a project dashboard, you should now have the possibility to click on an "Add a review" link. 
<br/>
<img src="http://sonar.codehaus.org/wp-content/uploads/2008/11/add_a_reviews.jpg" alt="" title="add_a_reviews" width="483" height="87" class="aligncenter size-full wp-image-180" />

<br/><br/>
Sonar will ask you first to create a review type and help you to switch on "Review types" tab under "Preferences" category :
<br/>
<img src="http://sonar.codehaus.org/wp-content/uploads/2008/11/review_types_administration.jpg" alt="" title="review_types_administration" width="600" height="112" class="aligncenter size-medium wp-image-181" />

<br/><br/>
You can define your new review type by specifying the name (ex : Configuration Management, Technical Design), an optional description and the kind of metrics you want to use (ex : Number, Percentage, Yes/No). Once your review type is created, just go back to the project dashboard and feed Sonar with the results of your different kind of reviews :
<br/>
<img src="http://sonar.codehaus.org/wp-content/uploads/2008/11/add_a_review_value.jpg" alt="" title="add_a_review_value" width="500" height="276" class="aligncenter size-full wp-image-183" />

<br/><br/>
Those reviews are now displayed on your project dashboard as the other classical metrics :
<br/>
<img src="http://sonar.codehaus.org/wp-content/uploads/2008/11/reviews_added.jpg" alt="" title="reviews_added" width="490" height="149" class="aligncenter size-full wp-image-184" />
<br/><br/>

Of course, the history of reviews is also accessible :
<br/>
<img src="http://sonar.codehaus.org/wp-content/uploads/2008/11/reviews_history.jpg" alt="" title="reviews_history" width="488" height="293" class="aligncenter size-full wp-image-185" />

<br/><br/>
So far, we have not communicated too much on this functionality as we thought its scope was not generic enough. Things are gonna change in version 1.5 as 
<ul>

	<li>We stop talking about "reviews" but rather about "manual measures".</li>
	<li>You'll be able to automatically define and calculate new metrics taht use those manual measures as well as classical measures like total complexity or code coverage.</li>
</ul>
<br/>
<b>You'll therefore have the necessary tool set to calculate your own company quality indicator.</b>
<img src="http://feeds.feedburner.com/~r/Sonar/~4/453424106" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://sonar.codehaus.org/using-the-reviews-section-on-the-project-dashboard/feed/</wfw:commentRss>
		<feedburner:origLink>http://sonar.codehaus.org/using-the-reviews-section-on-the-project-dashboard/</feedburner:origLink></item>
		<item>
		<title>Is 80% of code coverage any good ?</title>
		<link>http://feeds.feedburner.com/~r/Sonar/~3/453424107/</link>
		<comments>http://sonar.codehaus.org/is-80-of-code-coverage-any-good/#comments</comments>
		<pubDate>Wed, 29 Oct 2008 10:40:49 +0000</pubDate>
		<dc:creator>Olivier Gaudin</dc:creator>
		
		<category><![CDATA[blog]]></category>

		<guid isPermaLink="false">http://sonar.codehaus.org/?p=171</guid>
		<description><![CDATA[When talking about source code quality, there are always voices to tell you that metrics mean nothing and that plenty of projects have great metrics and poor quality...]]></description>
			<content:encoded><![CDATA[When talking about source code quality, there are always voices to tell you that metrics mean nothing and that plenty of projects have great metrics and poor quality ! Let's look at one particular metric: the code coverage by unit tests.
<br/><br/>

Evaluating the code coverage of an application means measuring the quantity of code that isexecuted and so automatically tested by your unit tests. So if you get 80% of code coverage on your application, it's really a good news as you can refactor and maintain your code securely. It's like driving a car with a fasten seat belt.  Ok, but imagine, even if it's a bit ridiculous for agile guys, that 80% of the code of a fairly big application is covered by less than 10 unit tests. Believe me, I've already encountered this situation in real life with a batch application (8'000 lines of code) in charge of manipulating text files.<span id="more-171"></span>
<br/><br/>
It raises two remarks : 
<ul>
	<li>Is that good to have 80% of the code covered by unit tests ? Definitely ! If you've already maintained an application you haven't written from start, you do certainly agree that it's far better to have 10 unit tests covering 80% of code than nothing.</li>
	<li>Ok, but when your seat belt is fasten does that mean you're driving well ? Unhappily not, it's only mean your seat belt is fasten.</li>
</ul>
<br/>So, what is it possible to conclude from the code coverage metric?
<br/><br/>
In fact let's start first by what you cannot conclude : having a high percentage of code coverage does not mean (without extra information that I will not discuss here) that you are doing good Test Driven Development (TDD).
<br/><br/>
Instead of looking at the code coverage, you must look at the non-code coverage and then you can conclude something : you know that at least XX% of your code is not covered by unit tests and that you need to do something about it. <strong><b>You've clearly identified a risk</b></strong> !<img src="http://feeds.feedburner.com/~r/Sonar/~4/453424107" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://sonar.codehaus.org/is-80-of-code-coverage-any-good/feed/</wfw:commentRss>
		<feedburner:origLink>http://sonar.codehaus.org/is-80-of-code-coverage-any-good/</feedburner:origLink></item>
		<item>
		<title>Sonar participates to the Valtech Days</title>
		<link>http://feeds.feedburner.com/~r/Sonar/~3/453424108/</link>
		<comments>http://sonar.codehaus.org/sonar-participates-to-the-valtech-days/#comments</comments>
		<pubDate>Tue, 14 Oct 2008 10:45:13 +0000</pubDate>
		<dc:creator>Freddy Mallet</dc:creator>
		
		<category><![CDATA[blog]]></category>

		<guid isPermaLink="false">http://sonar.codehaus.org/?p=169</guid>
		<description><![CDATA[Next week, on the 21st on 22nd of October, I am going to participate to the Valtech Days 2008 where [...]]]></description>
			<content:encoded><![CDATA[Next week, on the 21st on 22nd of October, I am going to participate to the <a href="http://www.valtech.fr/fr/index/valtech_days.html">Valtech Days 2008</a> where I have been invited by <a href="http://ericlefevre.net/">Eric Lefevre</a>. More than 300 participants are expected to this event, whose main topics are going to be this year : Agility, Industrialization and software factory, Java / .NET / SOA architecture, e-business and Web 2.0.
<br/><br/>

During the event, I am going to animate a session on "Industrialization of source code management" that I will co-present with <a href="http://linsolas.free.fr/pro-blog/">Romain Linsolas</a>,
<br/><br/>
<span id="more-169"></span>
For french speakers, I take the opportunity of this post to mention that Romain Linsolas has written a very valuable and detailed <a href="http://linsolas.developpez.com/articles/java/qualite/sonar/">article</a> on how to manage the source code quality of your java projects with Sonar...<img src="http://feeds.feedburner.com/~r/Sonar/~4/453424108" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://sonar.codehaus.org/sonar-participates-to-the-valtech-days/feed/</wfw:commentRss>
		<feedburner:origLink>http://sonar.codehaus.org/sonar-participates-to-the-valtech-days/</feedburner:origLink></item>
		<item>
		<title>Back from CITCON Europe 2008 in Amsterdam</title>
		<link>http://feeds.feedburner.com/~r/Sonar/~3/453424112/</link>
		<comments>http://sonar.codehaus.org/back-from-citcon-europe-2008-in-amsterdam/#comments</comments>
		<pubDate>Wed, 08 Oct 2008 20:31:15 +0000</pubDate>
		<dc:creator>Olivier Gaudin</dc:creator>
		
		<category><![CDATA[blog]]></category>

		<category><![CDATA[event]]></category>

		<guid isPermaLink="false">http://private.sonar.codehaus.org/?p=162</guid>
		<description><![CDATA[Last week-end, we attended CITCON Europe 2008 in Amsterdam.

We were really curious and impatient to discover the whole experience of [...]]]></description>
			<content:encoded><![CDATA[Last week-end, we attended <a href="http://www.citconf.com/amsterdam2008/" target="_blank">CITCON Europe 2008</a> in Amsterdam.
<br/><br/>
We were really curious and impatient to discover the whole experience of technological <a href="http://www.citconf.com/amsterdam2008/openspace.php">OpenSpace</a>: we were amazed to see how well it works and how things get organized quickly with so many people (&gt;100). On Friday evening, anybody had a chance to propose a session on a topic, by announcing it to the audience and hanging a post-it on a board. We then voted for the topics we were interested in and since there were still numerous sessions, similar topics were regrouped : that was it for setting up the agenda ! On Saturday, there were 5 time slots of an hour each during which were running 6 sessions at the time.<span id="more-162"></span>
<br/><br/>
<center><img class="aligncenter size-medium wp-image-164" title="The event schedule" src="http://sonar.codehaus.org/wp-content/uploads/2008/10/citcon-tableau.jpg" alt="" width="200" height="140" /></center>
<br/><br/>
In terms of content, a lot of the sessions were about integration / system / user testing (Selenium, user automated testing, issue with databases during test periods, automated acceptance tests, ...). Unlike for unit testing, no standard neither consensus seems to really emerge on integration, functional, user interface tests. We had interesting discussions and knowledge sharing sessions, but the conclusion was that the testing strategy to be put in place is highly dependent on the project type and the context.As expected, almost every continuous integration engine was represented and we even got a quick demo of each (open source first, obviously !) : <a href="http://sourceforge.net/projects/build-o-matic">Build-o-matic</a>, <a href="http://cruisecontrol.sourceforge.net/">CruiseControl</a>, <a href="https://hudson.dev.java.net/">Hudson</a>, <a href="http://studios.thoughtworks.com/cruise-continuous-integration">Cruise</a>, <a href="http://zutubi.com/products/pulse/">Pulse</a>, <a href="http://www.jetbrains.com/teamcity/">TeamCity</a> and <a href="http://www-01.ibm.com/software/awdtools/buildforge/enterprise/">BuildForge</a>.<br/>
Talking about CI engines, we met Sherali from <a href="http://www.atlassian.com/">Atlassian</a>, the company that develops <a href="http://www.atlassian.com/software/bamboo/">Bamboo</a>. We had a good time discussing software quality and talking about Atlassian's development in Europe.
<br/><br/>
We had proposed a session around Source Code Quality inside Continuous Integration. Around 30 people showed up to participate to the session.
<br/><br/>
<center><img class="aligncenter size-medium wp-image-163" title="Freddy in action…" src="http://sonar.codehaus.org/wp-content/uploads/2008/10/citcon-freddy.jpg" alt="" width="300" height="225" /></center>
<br/><br/>
We discussed source code quality as well as project metrics during the session. Participants had good experiences to share and ideas about how metrics could be improved. After some debate, we pretty much all agreed on some conclusions :
<ul>
	<li><strong>Showing good metrics does not prove that your project source code has a good quality</strong></li>
	<li><strong>Showing bad metrics proves that your project has a bad quality</strong></li>
	<li>Before measuring any metrics, it is absolutely necessary to define your objectives</li>
</ul><br/>
The last session we attended was : "Is scrum evil ?". Interesting session, probably proposed as a provocation, that highlighted to me two remarkable things :
<ul>
	<li>Whether they like scrum or hate scrum, people are passionate about scrum</li>
	<li>Out of the 70 or 80 participants to the session, I would say that 30% were Certified Scrum Master (SCM)</li>
</ul>
<br/>
To wrap up, CITCON was a very good event, where participants were motivated, happy to share experience, to brainstorm and to debate. The technological open spaces are great. I think it could be an idea to split between more formal and open space sessions. The open space sessions would then be a natural follow-up to the more formal ones. We will find that out anyway during the <a href="http://www.valtech.fr/fr/index/valtech_days.html">Valtech Days 2008</a> happening in 2 weeks where we have been invited by <a href="http://ericlefevre.net/" target="_blank">Eric Lefevre</a>.<img src="http://feeds.feedburner.com/~r/Sonar/~4/453424112" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://sonar.codehaus.org/back-from-citcon-europe-2008-in-amsterdam/feed/</wfw:commentRss>
		<feedburner:origLink>http://sonar.codehaus.org/back-from-citcon-europe-2008-in-amsterdam/</feedburner:origLink></item>
		<item>
		<title>A new Hudson plugin for a closer integration with Sonar</title>
		<link>http://feeds.feedburner.com/~r/Sonar/~3/453424113/</link>
		<comments>http://sonar.codehaus.org/a-new-hudson-plugin-for-a-closer-integration-with-sonar/#comments</comments>
		<pubDate>Tue, 30 Sep 2008 12:25:06 +0000</pubDate>
		<dc:creator>Simon Brandhof</dc:creator>
		
		<category><![CDATA[blog]]></category>

		<category><![CDATA[continuous integration]]></category>

		<category><![CDATA[hudson]]></category>

		<guid isPermaLink="false">http://private.sonar.codehaus.org/?p=153</guid>
		<description><![CDATA[Continuous integration (CI) has become a centerpiece of software development lifecycle. Since Sonar is implemented as a maven plugin, it [...]]]></description>
			<content:encoded><![CDATA[Continuous integration (CI) has become a centerpiece of <a href="http://www.javaworld.com/javaworld/jw-06-2007/jw-06-awci.html" target="_blank">software development lifecycle</a>. Since Sonar is implemented as a maven plugin, it can be easily integrated with any CI engine : the engine acts as the scheduler for Sonar's daily runs. You can even imagine to use the well known but a bit outdated cron scheduler to launch the maven goal "mvn org.codehaus.sonar:sonar-maven-plugin:1.4.2:sonar" on each project you want to analyse.
<br/><br/>
At this point in time, you are probably wondering : ok, but why would I need a plugin to integrate Sonar with <a href="http://hudson.gotdns.com/wiki/display/HUDSON/Home" target="_blank">Hudson</a>, the <a href="http://ericlefevre.net/wordpress/2007/06/14/agileopen-continuous-integration-with-hudson/" target="_blank">very popular</a>, open source and easy to use CI engine ? Is it possible to get an even more seamless integration ?
<span id="more-153"></span>
<br/><br/>
In fact, when you face a real enterprise context, you need to <a href="http://docs.codehaus.org/display/SONAR/Installation+guide+(v.+1.4)#Installationguide(v.1.4)-Step4ConfigureMaven2" target="_blank">configure your setting.xml file</a> by hand on your integration machine and copy/paste the Sonar maven goal for each project under control : 10, 50, 100, 200 times ... Life will be easier if you can :
<ul>
	<li>Prevent edition of the setting.xml file and directly edit and view the Sonar configuration from Hudson</li>
	<li>Define the Sonar maven goal only once and use it as often as often as you want</li>
</ul>
<br/><br/>
We've developed a Hudson plugin to provide those two missing features. All configuration is done online and is shared across projects, you can enable/disable Sonar analysis in one click for all your projects. Obviously, you still can override Sonar parameters at the project level. Imagine for instance, on a given project you don't want to import and display source code through Sonar interface for security reason (<a href="http://jira.codehaus.org/browse/SONAR-306" target="_blank">SONAR-306</a>).
<br/><br/>
<center><img src="http://sonar.codehaus.org/wp-content/uploads/2008/09/hudson_global.png" /> </center>That was the first step on planet Hudson and we wanted to go beyond. There is an unknown but yet useful <a href="http://docs.codehaus.org/display/SONAR/Installation+guide+(v.+1.4)#Installationguide(v.1.4)-ButmyprojectisnotbuiltwithMaven2?" target="_blank">Sonar functionality</a> which allows you to analyze any java projects even if they don't use Maven (perhaps you're still using Ant or don't use a build framework at all). Nevertheless, in that case you need to write by hands a short pom.xml file to provide to Sonar several mandatory parameters. This last tedious step has gone with <strong>version 0.2</strong> of the plugin.You just need to fill those basic parameters in the Hudson job configuration and quality analysis can start. If you're a code audit consultant and you need to quickly and efficiency analyze your customer's sources : just tell Sonar/Hudson couple where is the source director. <center><img src="http://sonar.codehaus.org/wp-content/uploads/2008/09/hudson-job.png" alt="hudson-job.png" /></center>Want to give it a try : just install the <a href="http://hudson.gotdns.com/wiki/display/HUDSON/Sonar+plugin">sonar plugin</a> from the Hudson management console. And... don't forget to install Hudson and Sonar before :-)<img src="http://feeds.feedburner.com/~r/Sonar/~4/453424113" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://sonar.codehaus.org/a-new-hudson-plugin-for-a-closer-integration-with-sonar/feed/</wfw:commentRss>
		<feedburner:origLink>http://sonar.codehaus.org/a-new-hudson-plugin-for-a-closer-integration-with-sonar/</feedburner:origLink></item>
		<item>
		<title>Bug-fix release 1.4.2</title>
		<link>http://feeds.feedburner.com/~r/Sonar/~3/453424114/</link>
		<comments>http://sonar.codehaus.org/bug-fix-release-142/#comments</comments>
		<pubDate>Thu, 25 Sep 2008 12:20:41 +0000</pubDate>
		<dc:creator>Sonar team</dc:creator>
		
		<category><![CDATA[blog]]></category>

		<category><![CDATA[release]]></category>

		<guid isPermaLink="false">http://private.sonar.codehaus.org/?p=152</guid>
		<description><![CDATA[The release 1.4.2 is available for <a href="http://sonar.codehaus.org/downloads">download</a> and fixes two bugs.]]></description>
			<content:encoded><![CDATA[The release 1.4.2 is available for <a href="http://sonar.codehaus.org/downloads">download</a>. It fixes two bugs :
<ul>
	<li><a href="http://jira.codehaus.org/browse/SONAR-344">SONAR-344</a> Configuration of custom rules is not read when importing checkstyle.xml file</li>

	<li><a href="http://jira.codehaus.org/browse/SONAR-351">SONAR-351</a> MySql broken pipe on inactivity timeout</li></ul>
<br/>
Upgrade steps from 1.4.* releases are :
<ul>
	<li>unzip the distribution</li>
	<li>replace sonar-1.4.2/conf/, sonar-1.4.2/extensions/ and sonar-1.4.2/data/ directories by yours</li>
	<li>If MySql database, add the following property to sonar-1.4.2/conf/sonar.properties :
<code>sonar.jdbc.validationQuery:   select 1</code>
</li>
	<li>start the server</li>
<li>update the maven plugin version :
<code>mvn org.codehaus.sonar:sonar-maven-plugin:1.4.2:sonar</code></li>
</ul><img src="http://feeds.feedburner.com/~r/Sonar/~4/453424114" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://sonar.codehaus.org/bug-fix-release-142/feed/</wfw:commentRss>
		<feedburner:origLink>http://sonar.codehaus.org/bug-fix-release-142/</feedburner:origLink></item>
	</channel>
</rss>
