sonarqube

SonarQube Coverage for Branch

谁都会走 提交于 2019-12-23 11:46:36
问题 Is it possible to get code coverage details for non-master branches in SonarQube? The only two tabs I see for other branches are Issues and Code . I am running the same Gradle JaCoCo/Sonar commands for each branch: ./gradlew report sonarqube -Dsonar.branch.name=${BITBUCKET_BRANCH} -Dsonar.organization=${SONARQUBE_ORG} -Dsonar.host.url=https://sonarcloud.io -Dsonar.login=${SONARQUBE_KEY} I am using PowerMockito so I need the class instrumentation done by the report task. We are using Java,

SonarQube 6.2 upgrade to 6.4 Missing projects and users

大城市里の小女人 提交于 2019-12-23 10:19:20
问题 On Debian Jessie I had an installed version of SonarQube 6.2 using Postgresql (latest on Jessie ) Java 8 installed I went through the upgrade process (to v. 6.4)Here When it came back online all the projects were missing. I can get to them by manually typing in the URL to the project like: https://[address of server]/dashboard?id=[Name of Project] Also the in the user admin section (Administration>Security>Users) I see no users. However if I go to groups (Administration>Security>Groups) my

SonarQube 6.2 upgrade to 6.4 Missing projects and users

走远了吗. 提交于 2019-12-23 10:17:17
问题 On Debian Jessie I had an installed version of SonarQube 6.2 using Postgresql (latest on Jessie ) Java 8 installed I went through the upgrade process (to v. 6.4)Here When it came back online all the projects were missing. I can get to them by manually typing in the URL to the project like: https://[address of server]/dashboard?id=[Name of Project] Also the in the user admin section (Administration>Security>Users) I see no users. However if I go to groups (Administration>Security>Groups) my

@SuppressWarnings more than one rule not working

♀尐吖头ヾ 提交于 2019-12-23 10:14:16
问题 PMD and SonarQube a nice tools but I have problems trying to suppress PMD warnings. We use Lombok a lot in our project, so many of the model classes have a: @SuppressWarnings("PMD.UnusedPrivateField") as an class-level annotations. This works fine. The problem is, that if I wan't to ignore one more rule, I would expect the following syntax: @SuppressWarnings(value = { "PMD.UnusedPrivateField", "PMD.SingularField" }) This looks like the correct syntax, also reading the implementation of the

Import FindBugs configuration from Sonar to Maven

不羁岁月 提交于 2019-12-23 09:30:36
问题 How can I use a FindBugs configuration file from Sonar as the rule set in the Maven FindBugs plugin? 回答1: You can place your file, i.e. findbugs-sonar.xml in the src/main/resource folder and specify the path in your maven reporting settings like this: <reporting> <plugins> <plugin> <groupId>org.codehaus.mojo</groupId> <artifactId>findbugs-maven-plugin</artifactId> <version>2.5.3-SNAPSHOT</version> <configuration> <includeFilterFile>findbugs-sonar.xml</includeFilterFile> </configuration> <

Sonar fails to connect to database

喜欢而已 提交于 2019-12-23 08:59:20
问题 I am using the following software: Sonar 3.4.1 Mysql 5.1 Maven 2.2.1 Tomcat 7 I have a pom.xml file which I am trying to execute with Sonar but getting the follwing error. [INFO] Building asgard-bpm [INFO] task-segment: [sonar:sonar] (aggregator-style) [INFO] ----------------------------------------------------------------------- [INFO] [sonar:sonar {execution: default-cli}] [INFO] Sonar host: http://{host:8080}/sonar [INFO] Sonar version: 3.4.1 [INFO] Execute: org.codehaus.sonar:sonar-maven

sonarqube “new code” definition

℡╲_俬逩灬. 提交于 2019-12-23 08:55:29
问题 Re the default quality gate, strangely, we are unclear of the definition “new code”! To illustrate, let’s say we change a file by adding new code. Is default sonar quality gate analysis done on only the new lines of code or the whole file? We are unclear but suspect it is the whole file! I’m being told by colleagues that projects are failing quality gate because files with pre-existing blockers etc. were touched/changed. Any clarification would be much appreciated. 回答1: First, analysis will

Create new user in sonar

妖精的绣舞 提交于 2019-12-23 07:47:18
问题 Is it possible to create a new user in sonar without using the web interface? I need to write a script that inserts the same users for some tools, including sonar. 回答1: There are three ways you can do this: Write directly to the database (there is a simple table called users). Use the LDAP plugin, if you specify sonar.authenticator.createUsers: true in sonar.properties, it will create the users in the sonar database automatically the first time they authenticate. Write a java application that

SonarQube exits with 143

孤人 提交于 2019-12-23 07:38:21
问题 I am trying to Setup SonarQube on Centos 6 VM with 6GB of RAM. The process always exits with 143. On analysis I found that the JVM is being sent a SIGTERM signal and thus exiting. There are no core dumps and dmesg is also quite unhelpful. I also tried fiddling with the Memory options to no avail. If some can help me debug this issue it will be quite useful. At least, I will have some idea why this software is being terminated. jvm 1 | 2018.03.06 15:32:59 INFO app[][o.e.p.PluginsService] no

Sonarqube 4.5.4 : Mysql deadlock

喜夏-厌秋 提交于 2019-12-23 07:27:53
问题 I am using sonarqube 4.5.4 with mysql database. I got this exception when running analysis on my projects : INFO o.d.m.sonar.runner.RunSonarVisitor - ### Error updating database. Cause: com.mysql.jdbc.exceptions.jdbc4.MySQLTransactionRollbackException: Deadlock found when trying to get lock; try restarting transaction 2016-02-23 04:05:40.091Z INFO o.d.m.sonar.runner.RunSonarVisitor - ### The error may involve org.sonar.core.user.RoleMapper.insertGroupRole-Inline 2016-02-23 04:05:40.091Z INFO