For code coverage, you need Cobertura to generate its report in XML. I tried:
ant clean test -Dtest.cobertura=true -Dcobertura.report.format=xml > , but Cobertura fails to generate the XML report (whereas it's ok when it's generating it in HTML...). So as long as this doesn't work, you won't be able to get coverage... at least with Cobertura. Also, I hadn't noticed that you had changed the project key, so now you have 2 different projects on SQ: - The original one: https://analysis.apache.org/dashboard/index/org.apache.tomcat:tomcat-parent - From what I can see, looks like at some point of time, Tomcat was fully built with Maven? - The new one: https://analysis.apache.org/dashboard/index/apache:tomcat You should keep only one. I suggest that you: - delete <http://docs.codehaus.org/display/SONAR/Project+Administration#ProjectAdministration-DeletingaProject> the new one - and update the key <http://docs.codehaus.org/display/SONAR/Project+Administration#ProjectAdministration-UpdatingProjectKey> of the original one to "apache:tomcat" , this will you'll keep the (short) history of the original analyses. - Fabrice belling...@apache.org fabrice.belling...@sonarsource.com On Thu, Sep 11, 2014 at 1:20 PM, Olivier Lamy <ol...@apache.org> wrote: > thanks. > Looks better now except code coverage still doesn't work. Any idea? > > On 10 September 2014 22:12, Fabrice Bellingard <belling...@gmail.com> > wrote: > > Hi Olivier, > > > > Looks like the configuration of the SQ build step is not fully correct. > From > > the following command line: > >> > >> [workspace] $ /x1/jenkins/sonar-runner/bin/sonar-runner > >> -Dsonar.jdbc.driver=com.mysql.jdbc.Driver > >> > >> -Dsonar.jdbc.url=jdbc:mysql:// > 192.168.0.64:3306/sonar?useUnicode=true&characterEncoding=utf8 > >> ******** ******** > >> -Dsonar.host.url=http://localhost:9090 ******** ******** > >> > >> > -Dsonar.projectBaseDir=/x1/jenkins/jenkins-master/jenkins-home/jobs/tomcat-trunk/workspace > >> "-Dsonar.projectName=Apache Tomcat" > >> -Dsonar.projectVersion=trunk > >> -Dsonar.libraries=output/classes > >> -Dsonar.projectKey=apache:tomcat > >> > -Dsonar.sources=java,modules/jdbc-pool,modules/tomcat-lite,modules/bayeux > > > > , I can see that: > > > > sonar.binaries is missing (which is the reason why the Findbugs plugins > > fails) > > sonar.libraries is not correct (it points to the folder where classes are > > compiled, not to the dependencies) > > > > > > I made some tests on my box, and the following configuration should make > it: > > > >> sonar.projectKey=apache:tomcat > >> sonar.projectName=Apache Tomcat > >> sonar.projectVersion=trunk > >> > >> > sonar.sources=java,modules/bayeux/java,modules/jdbc-pool/src/main/java,modules/tomcat-lite/java > >> > >> > sonar.binaries=output/classes,modules/jdbc-pool/output/classes,modules/tomcat-lite/target/classes > > > > > > (I removed "sonar.libraries" because it depends on the "base.path" > property > > set for the build) > > > > > > One note: if you want to benefit from Findbugs analysis, all the classes > > need to compiled. For my tests, I run: > > > > "ant compile" at the root, which compiles into "output/classes" > > "ant" for both bayeux module, which compiles into "output/classes" as > well > > "ant" for jdbc-pool module, which compiles into > > "modules/jdbc-pool/output/classes" > > "mvn compile" for "tomcat-lite" module, which compiles into > > "modules/tomcat-lite/target/classes" > > > > All those build directories are therefore referenced in "sonar.binaries". > > > > > > HTH! > > > > - Fabrice > > belling...@apache.org > > fabrice.belling...@sonarsource.com > > > > On Wed, Sep 10, 2014 at 9:08 AM, Olivier Lamy <ol...@apache.org> wrote: > >> > >> I tried to get this working but got this error: > >> https://analysis.apache.org/jenkins/job/tomcat-trunk/10/console > >> > >> Any help will be appreciate :-) > >> > >> > >> On 3 September 2014 22:07, Fabrice Bellingard <belling...@gmail.com> > >> wrote: > >> > Hi guys, > >> > > >> > Tomcat had also been analyzed for a couple of months on the SonarQube > >> > instance of the ASF [1], but the last analysis is very old. The > analysis > >> > must be failing for some reasons, so I copy Olivier who's managing the > >> > SQ > >> > instance @ASF. He can certainly give you more information on how to > get > >> > the > >> > analysis back to normal - and probably also how to get a login there. > >> > > >> > IMO, it's best to advertise and use this instance instead of Nemo - > >> > which we > >> > use @SonarSource mainly as a demo instance. > >> > > >> > [1] https://analysis.apache.org/dashboard/index/77101?did=1 > >> > > >> > > >> > - Fabrice > >> > belling...@apache.org > >> > fabrice.belling...@sonarsource.com > >> > > >> > > >> >> From: Henri Gomez <henri.go...@gmail.com> > >> >> Date: Wed, Aug 27, 2014 at 12:00 PM > >> >> Subject: Re: Coverity static analysis scanning > >> >> To: Tomcat Developers List <dev@tomcat.apache.org>, Fabrice > Bellingard > >> >> <fabrice.belling...@sonarsource.com> > >> >> > >> >> > >> >> Fabrice Belingard, ASFer is working for Sonar. > >> >> I add him in loop so he could give us more informations > >> >> > >> >> 2014-08-27 11:45 GMT+02:00 Mark Thomas <ma...@apache.org>: > >> >> > On 26/08/2014 22:52, Henri Gomez wrote: > >> >> >> Hi all > >> >> >> > >> >> >> Are you aware SonarQube is analysing Tomcat in Nemo for years ? > >> >> >> > >> >> >> > >> >> >> http://nemo.sonarqube.org/dashboard/index/50544 > >> >> >> > >> >> >> 310 Blocker issues, 121 Critical issues. > >> >> > > >> >> > I took a quick look. The first 60 or so blocker issues I looked at > >> >> > were > >> >> > all false positives triggered by us catching Throwable for good > >> >> > reasons. > >> >> > Can we get a login to this system to make them as false positives? > >> >> > > >> >> > Mark > >> >> > > >> >> > > >> >> >> > >> >> >> Wondering if Coverity will provides more informations than > SonarQube > >> >> >> ? > >> >> >> > >> >> >> BTW, SonarQube is analysing major ASF projects for a long time now > >> >> >> :) > >> >> >> > >> >> >> > >> >> >> 2014-08-26 11:20 GMT+02:00 Mark Thomas <ma...@apache.org>: > >> >> >>> All, > >> >> >>> > >> >> >>> I have been pinged off-list by Coverity to say that they have set > >> >> >>> up > >> >> >>> Tomcat with a free account with their static code analysis > service. > >> >> >>> > >> >> >>> I think I have the ability to send invitations so if anyone wants > >> >> >>> to > >> >> >>> take a look at the results, just reply here. > >> >> >>> > >> >> >>> I have taken a quick look and they do appear to have found some > >> >> >>> valid > >> >> >>> threading issues. There are ~350 issues in total and I don't yet > >> >> >>> have > >> >> >>> a > >> >> >>> feel for the false positive rate. > >> >> >>> > >> >> >>> Mark > >> >> >>> > >> >> >>> > >> >> >>> > --------------------------------------------------------------------- > >> >> >>> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org > >> >> >>> For additional commands, e-mail: dev-h...@tomcat.apache.org > >> >> >>> > >> >> >> > >> >> >> > >> >> >> > --------------------------------------------------------------------- > >> >> >> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org > >> >> >> For additional commands, e-mail: dev-h...@tomcat.apache.org > >> >> >> > >> >> > > >> >> > > >> >> > > --------------------------------------------------------------------- > >> >> > To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org > >> >> > For additional commands, e-mail: dev-h...@tomcat.apache.org > >> >> > > >> >> > >> > > >> > >> > >> > >> -- > >> Olivier Lamy > >> http://twitter.com/olamy | http://linkedin.com/in/olamy > > > > > > > > -- > Olivier Lamy > http://twitter.com/olamy | http://linkedin.com/in/olamy >