本文介绍了声纳Qube 5.3中不推荐使用sonar.Qualitygate.有什么选择?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

上下文:在Sonar Qube中,存在一个自定义的质量门,称为"abcd".这不是默认的质量门.在Jenkins中,我通过使用参数为一组API配置了SonarQube Quality Gate-Dsonar.QualityGate=abcd并且运行正常.

Context: In Sonar Qube, there exists a custom Quality Gate which is called say abcd. This is NOT the default quality gate. And in Jenkins, I had configured this SonarQube Quality Gate for a set of APIs by using the parameter -Dsonar.QualityGate=abcd and it was working fine.

最近Sonar Qube已升级到5.3版.从那时起,abcd质量门不起作用,并且默认质量门开始起作用,而不是所有API的abcd质量门.

Recently Sonar Qube was upgraded to version 5.3. Since then, the abcd quality gate is not working and the default quality gate is coming into play instead of the abcd quality gate for all the APIs.

经过分析,我知道sonar.QualityGate在5.3版中已弃用.

On analysis, I came to know that sonar.QualityGate is deprecated in Version 5.3.

问题:能否让我知道替代方法是什么?以及如何确保这些API集将abcd作为质量门而不是默认质量门?

Question: Can you please let me know what is the alternative? And how do I make sure that these set of APIs have abcd as the quality gate and not the default quality gate?

我希望有一个解决方案,以便可以在Jenkins上配置某些内容,因为我可以访问Jenkins,但不能访问Sonar Qube配置.

I would prefer a solution such that I can configure something on Jenkins as I have access to Jenkins but not to Sonar Qube configurations.

推荐答案

在运行分析时,使用参数设置项目的质量门确实不再可行.只有在UI/WS上才有可能,您可以在其中指定应将哪个Quality Gate用于哪个项目.

It's indeed no more possible to set the Quality Gate of a project using a parameter when running an analysis.It's only possible from the UI/WS, where you can specify which Quality Gate should be used for which project.

有关更多信息,请参见文档: http://docs.sonarqube.org/display /SONAR/Quality + Gates .

See the documentation for more information : http://docs.sonarqube.org/display/SONAR/Quality+Gates.

这篇关于声纳Qube 5.3中不推荐使用sonar.Qualitygate.有什么选择?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

09-17 09:03