I have setup a project with a specific date in sonar.timemachine.period5 in my project.properties file. This usually works perfectly, but sometimes the sonarqube runner doesn't make the comparison.
sonar.timemachine.period5=2015-11-04
Here is a part of the log output from two consecutive sonar-runner analysis:
This one is not comparing against period 5:
10:28:17.546 INFO - Loaded quality gate 'MyProject'
10:28:17.591 INFO - Compare to previous analysis (2015-10-26)
10:28:17.596 INFO - Compare over 30 days (2015-10-24, analysis of Mon Oct 26 09:26:01 CET 2015)
10:28:17.597 INFO - Compare to previous version (2015-10-26)
while this one is....
10:37:43.996 INFO - Loaded quality gate 'MyProject'
10:37:44.054 INFO - Compare to previous analysis (2015-11-23)
10:37:44.060 INFO - Compare over 30 days (2015-10-24, analysis of Mon Oct 26 09:26:01 CET 2015)
10:37:44.061 INFO - Compare to previous version (2015-11-23)
10:37:44.062 INFO - Compare to date 2015-11-04 (analysis of 2015-11-23
Any clues on why this is happening?
The result is that the project sometimes passes the qualitygate when it certainly shouldn't.
Im running SonarQube 5.1.2 and using Sonar-Runner 2.4
Periods 4 and 5 are not set globally but on the project level. Double-check your first project to make sure it has a valid Period 5 value.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.