sonarqube

Failed to execute goal org.sonarsource.scanner.maven:sonar-maven-plugin: 3.2:sonar

拟墨画扇 提交于 2020-01-23 08:14:29
问题 Can anyone help me in getting solution for the below error. Below are the version of the components to configure SonarQube 5.1.2 Soanr-Runner 2.4 Java 1.7 [ I have to use 1.7 only since my code supports only 1.7 ] mavn 3.3.9 sonar-cobertura-plugin-1.6.3 sonar-findbugs-plugin-3.3 cobertura 2.6 Execution command mvn -fn -e org.sonarsource.scanner.maven:sonar-maven-plugin:RELEASE:sonar -Dsonar.jdbc.url="jdbc:mysql://localhost:3306/sonar?useUnicode=true&characterEncoding=utf8

Failed to execute goal org.sonarsource.scanner.maven:sonar-maven-plugin: 3.2:sonar

杀马特。学长 韩版系。学妹 提交于 2020-01-23 08:13:27
问题 Can anyone help me in getting solution for the below error. Below are the version of the components to configure SonarQube 5.1.2 Soanr-Runner 2.4 Java 1.7 [ I have to use 1.7 only since my code supports only 1.7 ] mavn 3.3.9 sonar-cobertura-plugin-1.6.3 sonar-findbugs-plugin-3.3 cobertura 2.6 Execution command mvn -fn -e org.sonarsource.scanner.maven:sonar-maven-plugin:RELEASE:sonar -Dsonar.jdbc.url="jdbc:mysql://localhost:3306/sonar?useUnicode=true&characterEncoding=utf8

How to inspect a json response from Ansible URI call

烂漫一生 提交于 2020-01-23 06:41:06
问题 I have a service call that returns system status in json format. I want to use the ansible URI module to make the call and then inspect the response to decide whether the system is up or down {"id":"20161024140306","version":"5.6.1","status":"UP"} This would be the json that is returned This is the ansible task that makes a call: - name: check sonar web is up uri: url: http://sonarhost:9000/sonar/api/system/status method: GET return_content: yes status_code: 200 body_format: json register:

tmatesoft.svn.core.SVNAuthenticationException: svn: E170001

久未见 提交于 2020-01-23 06:33:28
问题 We are working n a legacy project (maven) to setup devop. Starter with jenkins. Jenkins build is now without issues. But, while integrating sonarqube with jenkins, we are getting the following error: ERROR: Error during SonarQube Scanner execution java.lang.IllegalStateException: Error when executing blame for file src/main/java/com/acme/acq/scavenger/AssetCmboItem.java at org.sonar.plugins.scm.svn.SvnBlameCommand.blame(SvnBlameCommand.java:100) at org.sonar.plugins.scm.svn.SvnBlameCommand

SONAR: Replace this lambda with a method reference

自作多情 提交于 2020-01-23 04:32:20
问题 Sonar tells me "Replace this lambda with a method reference" public class MyClass { private List<SomeValue> createSomeValues(List<Anything> anyList) { return anyList // .stream() // .map(anything -> createSomeValue(anything)) // .collect(Collectors.toList()); } private SomeValue createSomeValue(Anything anything) { StatusId statusId = statusId.fromId(anything.getStatus().getStatusId()); return new SomeValue(anything.getExternId(), statusId); } } Is this possible here? I tried several things,

sonar的安装以及使用

|▌冷眼眸甩不掉的悲伤 提交于 2020-01-22 01:20:55
SonarQube是管理代码质量一个开放平台,可以快速的定位代码中潜在的或者明显的错误. 1. 简介 Sonar是一个用于代码质量管理的开源平台,用于管理代码的质量,通过插件形式可以支持二十几种语言的代码质量检测,通过多个维度的检查了快速定位代码中潜在的或者明显的错误。SonarQube是sonar的服务端,相当于一个web服务器中的tomcat,用来发布应用,在线浏览分析等. 2.安装 由于我本地安装的jdk是1.8版本,所以只能安装Sonar 7.8以下版本了,7.9以上需要安装JDK11才能支持了。快速下载链接,直连 https://www.sonarqube.org/downloads/ 下载完成后解压后点击StartSonar.bat启动即可,如下: 在双击之前,需要修改一下配置文件wrapper.conf,指定自己的jdk路径 启动成功后的界面是这样的, http访问9000端口出现下面则证明安装成功。 3.配置数据库 1. 在mysql数据库新建一个库的名称为sonar 2. 修改sonar/conf/sonar.properties的db信息 sonar.jdbc.username=root sonar.jdbc.password=root sonar.jdbc.url=jdbc:mysql://localhost:3306/sonar?useUnicode

sonarqube 5.6 & LDAP 2.0 failing to authenticate

試著忘記壹切 提交于 2020-01-21 05:11:26
问题 I am testing an upgrade to sonarqube 5.6 and have installed the ldap 2.0 plugin & copied the relevant configuration forward to my test 5.6 setup. The relevant config is sonar.security.realm=LDAP ldap.url=ldaps://xxxx:636 ldap.bindDn=uid=xxxx,ou=xxxx,dc=xxxx,dc=xxxx ldap.bindPassword=xxxx ldap.user.baseDn=dc=xxxx,dc=com ldap.user.request=(&(objectClass=person)(mail={login})) ldap.user.realNameAttribute=cn ldap.user.emailAttribute=mail I have the following set in conf/sonar.properties sonar.log

SonarQube MSBuild Scanner doesn't exclude files from analysis

两盒软妹~` 提交于 2020-01-21 01:42:06
问题 We are currently using SonarQube Scanner for VSTS/TFS 4.1.1 (which is using SonarQube Scanner 4.1.1). What we want to do: For some projects (modules) in our solution we want to exclude files from the analysis and from the code coverage statistics. This should be done in a maintainable way by using file patterns and not modifying the TFS Build task. Project structure: |- Source |- ProjectA |- Scripts (should be excluded) |- OwnCode |- ProjectB |- Views (only code coverage should be excluded) |

SonarQube代码质量扫描持续集成

末鹿安然 提交于 2020-01-20 00:06:42
1、安装JDK和配置JAVA_HOME和CLASSPATH 2、安装mysql数据库 3、创建数据库和用户 mysql -u root -p mysql> CREATE DATABASE sonar CHARACTER SET utf8 COLLATE utf8_general_ci; mysql> CREATE USER 'sonar' IDENTIFIED BY 'sonar'; mysql> GRANT ALL ON sonar.* TO 'sonar'@'%' IDENTIFIED BY 'sonar'; mysql> GRANT ALL ON sonar.* TO 'sonar'@'localhost' IDENTIFIED BY 'sonar'; mysql> FLUSH PRIVILEGES; 4、下载sonarqube wget https://sonarsource.bintray.com/Distribution/sonarqube/sonarqube-5.4.zip unzip sonarqube-5.4.zip vi /etc/profile SONAR_HOME=/usr/jenkins/sonarqube-5.4 export SONAR_HOME source /etc/profile 5、配置sonarqube

部署SonarQube代码检测服务以及jenkins实现代码自动测试、自动部署

狂风中的少年 提交于 2020-01-20 00:06:35
1.SonarQube部署前的内核参数等配置以及java环境配置 1)修改内核参数配置,使满足环境要求 [root@sonarqube ~]# vim /etc/sysctl.conf vm.max_map_count=262144 fs.file-max=65536 [root@sonarqube ~]# sysctl -p #生效修改的内核参数 …… vm.max_map_count = 262144 fs.file-max = 65536 2)修改本机安全策略参数限制 [root@sonarqube ~]# vim /etc/security/limits.conf …… sonarqube - nofile 65536 sonarqube - nproc 2048 3)配置java环境(至少jdk-8或openjdk-8版本) [root@sonarqube ~]# ls /usr/local/src/ jdk-8u211-linux-x64.tar.gz [root@sonarqube src]# tar xvf jdk-8u211-linux-x64.tar.gz [root@sonarqube src]#ln -sv jdk1.8.0_211 jdk [root@sonarqube src]#ln -sv jdk [root@sonarqube src]# ln