sonarqube

Sonar-Runner talks to the local database

独自空忆成欢 提交于 2019-12-10 07:09:09
问题 I am trying to understand the sonar-runner http://docs.sonarqube.org/display/SONAR/Installing+and+Configuring+SonarQube+Runner. I have a central sonar server that has a database in the same host. As expected I run the sonar-runner from my clients in numerous boxes and expect them to upload data to the sonar cube. My sonar-project.properties looks something like below # Required metadata sonar.projectKey=a:b sonar.projectName=b-1.0 sonar.projectVersion=1.0 # Comma-separated paths to

gwt-test-utils unit fail when run with jacoco

左心房为你撑大大i 提交于 2019-12-10 05:19:36
问题 We are attempting to generate coverage reports for our GWT application from a set of unit tests written using gwt-test-utils. The project is a multi-module maven project. We are using the sonar-plugin on jenkins in order to generate and collate our coverage and violation information. When the build jobs run all the GWT unit tests pass as part of the normal build, however when the Sonar plugin attempts to rerun the tests they all fail with the following error: initializationError(uk.co.card

SonarQube: How to suppress a warning in Kotlin code

孤者浪人 提交于 2019-12-10 02:59:00
问题 I'm using SQ 7.3-alpha1 with sonar-kotlin-plugin-1.0.1.965.jar. However, I cannot deactivate a special warning inside my Kotlin code for repositories in Spring Data where I need an "_" in a method name. I tried both //NOSONAR and @Suppress("kotlin:S100") and @SuppressWarnings("kotlin:S100") . Any hint is appreciated. 回答1: You're not able to deactivate that issue because none of the mechanisms you're trying to use have been implemented for Kotlin. Instead, you'll have to do this from the UI

@Nullable and SonarQube 'Conditionally executed blocks should be reachable' warning

99封情书 提交于 2019-12-10 02:48:41
问题 Package has following package-info.java: @ParametersAreNonnullByDefault package foo; import javax.annotation.ParametersAreNonnullByDefault; Class has the following method: private static String toIsoString(@Nullable Instant dateTime) { return dateTime == null ? null : dateTime.toString(); } On which SonarQube (Version 6.2, SonarJava 4.14.0.11784) gives the following warning (squid:S2583): How can I convince SonarQube that the code is actually correct? Interestingly, SonarLint plugin (3.0.0

Does SonarQube support Java9?

拈花ヽ惹草 提交于 2019-12-10 02:35:06
问题 The question is actually twofold: Can Java9 projects be analysed with SonarQube? Can SonarQube itself run on a Java9 JVM? Same question for Java8 回答1: TL;DR: YES!!! It supports analysis, apparently since 3rd July 2017 (But they are desperately trying to hide the fact...) As of now (2017-10-24, SonarQube version 6.6), SonarQube can analyse Java9 code using SonarJava 4.11 or newer, but running on a Java9 JVM is not officially supported . SonarQube Java Plugin compatibility The SonarJava page

Associating a Project to Sonar in Eclipse

只谈情不闲聊 提交于 2019-12-10 02:33:44
问题 I have Eclipse Indigo 3.7 base with MyEclipse 10 Java enterprise development plug-in: I have installed Sonar plug-in for eclipse. Installed Sonar server and running it locally from localhost (localhost:9000) Tested the Server connection in Eclipse from Windows>Preferences>Sonar>Servers. Connection is successful. For my Project, ran the Maven goal for sonar (sonar:sonar). Build is successful. I am able to browse the results in localhost. (localhost:9000) My issue is with Associating the

WARN web[o.s.s.n.NotificationService] Unable to deliver notification

≯℡__Kan透↙ 提交于 2019-12-09 19:05:04
问题 I did get this error when I've upgraded from 5.0 to 5.1. It was related to https://jira.codehaus.org/browse/SONAR-4778. See http://sonarqube.15.x6.nabble.com/WARN-web-o-s-s-n-NotificationService-Unable-to-deliver-notification-td5035238.html for details. It was a bug and it was supposed to be fixed in 5.1.1 with https://jira.codehaus.org/browse/SONAR-6566 as Simon Brandhof stated. Now I've upgraded to 5.1.1 and I'm still having the same problem. 2015.06.09 09:52:48 WARN web[o.s.s.n

How to use the Build Breaker on sonarqube 5.1+ if a project quality gate fails

风流意气都作罢 提交于 2019-12-09 18:36:09
问题 I am using Jenkins Continuous Integration server and Sonarqube for code coverage. I want to make sure that if the issues in the project reach a threshold value of Quality Gate , the project build should fail. I have installed Build Breaker plugin in Sonarqube . I read somewhere that it applies on each and every project by default and sends build failed report to CI server(Jenkins in my case). But this is not happening. My project builds are successful on CI server even if the issues have

Sonar Xerces conflict Findbugs and ivy:report

扶醉桌前 提交于 2019-12-09 16:27:53
问题 I am trying to get sonar to work for a project with a quality profile that includes Findbugs rules. However when analyzing the project the sonar anttask chrashes with the following error: Caused by: java.io.IOException: SAX2 driver class org.apache.xerces.parsers.SAXParser not found at edu.umd.cs.findbugs.filter.Filter.<init>(Filter.java:134) at edu.umd.cs.findbugs.FindBugs.configureFilter(FindBugs.java:516) at edu.umd.cs.findbugs.FindBugs2.addFilter(FindBugs2.java:374) at org.sonar.plugins

SonarQube安装

早过忘川 提交于 2019-12-09 16:25:13
一、概述 SonarQube是一个用于管理代码质量的开放平台,可以快速的定位代码中潜在的或者明显的错误。目前支持java,C#,C/C++,Python,PL/SQL,Cobol,JavaScrip,Groovy等二十几种编程语言的代码质量管理与检测。 SonarQube特性 持续检查 项目整体的健康程度 项目的主页面会给出,项目整体的Bugs、Vulnerabilities、Code Smells 专注于漏洞 water-leak-paradigm可以有效的管理代码质量:新特性,增加的,改变的 (water-leak-paradigm是sonarqube研究的一种代码管理方法) 在项目监测报告中,需要密切关注:New Bugs、New Vulnerabilities 实施质量阈值 在团队项目中,可以设置质量阈值(Quality Gate),用于监管质量 分支分析 确保干净的代码才会被合并到主分支中 监测棘手的问题 多语言 支持:ABAP、C/C++、C#、CSS、COBOL、Flex、Go、HTML、Java、JavaScript、Kotlin、Objective-C、PL/SQL、PL/I、PHP、Python、RPG、Ruby、Swift、T-SQL、TypeScript、VB.NET、VB6 XML 集成DevOps 集中质量 七个维度检测代码质量 复杂度分布