简体   繁体   English

Jenkins警告插件和SonarQube扫描仪

[英]Jenkins Warning Plugin and SonarQube Scanner

For my project, I want use the Warning Plugin on Jenkins. 对于我的项目,我想在Jenkins上使用警告插件。 The result is a XML file. 结果是一个XML文件。 And I have a plugin SonarQube for read this file. 我有一个SonarQube插件可以读取此文件。

However, the Warning plugin is execute after the Sonar Scanner analysis. 但是,警告插件是在声纳扫描仪分析后执行的。 Warning plugin is in "Post build actions" and the Sonar Scanner analysis is in "Post build step". 警告插件在“构建后的动作”中,而Sonar Scanner分析在“构建后的步骤”中。 So the XML file can't be read by my SonarQube Plugin cause this file doesn't exist when the SonarQube Scanner runs. 因此,我的SonarQube插件无法读取XML文件,因为在运行SonarQube Scanner时该文件不存在。

Someone has a solution ? 有人有解决办法吗?

Thanks a lot guys. 非常感谢。

You have to create another Job to read the XML in Post build actions. 您必须创建另一个Job来读取Post构建操作中的XML。 So in your current Job you must execute the plugin in Post build actions to create the XML. 因此,在您当前的Job中,您必须在Post build actions中执行插件以创建XML。 So in Post build step call the new job created. 因此,在后期构建步骤中,调用创建的新作业。 It makes the XML enable to read. 它使XML能够读取。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM