Skip to content
This repository has been archived by the owner on Feb 26, 2020. It is now read-only.

Commit

Permalink
Browse files Browse the repository at this point in the history
[FIXED JENKINS-4912] Fixed build health and threshold evaluation of m2
jobs.
  • Loading branch information
uhafner committed May 1, 2011
1 parent db9c301 commit 3464ac5
Show file tree
Hide file tree
Showing 2 changed files with 45 additions and 18 deletions.
2 changes: 1 addition & 1 deletion pom.xml
Expand Up @@ -36,7 +36,7 @@
<dependency>
<groupId>org.jvnet.hudson.plugins</groupId>
<artifactId>analysis-core</artifactId>
<version>1.19</version>
<version>1.20-SNAPSHOT</version>
</dependency>
<dependency>
<groupId>org.jvnet.hudson.plugins</groupId>
Expand Down
61 changes: 44 additions & 17 deletions src/main/java/hudson/plugins/pmd/PmdReporter.java
Expand Up @@ -37,18 +37,6 @@ public class PmdReporter extends HealthAwareMavenReporter {
/**
* Creates a new instance of <code>PmdReporter</code>.
*
* @param threshold
* Annotation threshold to be reached if a build should be considered as
* unstable.
* @param newThreshold
* New annotations threshold to be reached if a build should be
* considered as unstable.
* @param failureThreshold
* Annotation threshold to be reached if a build should be considered as
* failure.
* @param newFailureThreshold
* New annotations threshold to be reached if a build should be
* considered as failure.
* @param healthy
* Report health as 100% when the number of warnings is less than
* this value
Expand All @@ -58,17 +46,56 @@ public class PmdReporter extends HealthAwareMavenReporter {
* @param thresholdLimit
* determines which warning priorities should be considered when
* evaluating the build stability and health
* @param unstableTotalAll
* annotation threshold
* @param unstableTotalHigh
* annotation threshold
* @param unstableTotalNormal
* annotation threshold
* @param unstableTotalLow
* annotation threshold
* @param unstableNewAll
* annotation threshold
* @param unstableNewHigh
* annotation threshold
* @param unstableNewNormal
* annotation threshold
* @param unstableNewLow
* annotation threshold
* @param failedTotalAll
* annotation threshold
* @param failedTotalHigh
* annotation threshold
* @param failedTotalNormal
* annotation threshold
* @param failedTotalLow
* annotation threshold
* @param failedNewAll
* annotation threshold
* @param failedNewHigh
* annotation threshold
* @param failedNewNormal
* annotation threshold
* @param failedNewLow
* annotation threshold
* @param canRunOnFailed
* determines whether the plug-in can run for failed builds, too
*/
// CHECKSTYLE:OFF
@SuppressWarnings("PMD.ExcessiveParameterList")
@DataBoundConstructor
public PmdReporter(final String threshold, final String newThreshold,
final String failureThreshold, final String newFailureThreshold,
final String healthy, final String unHealthy, final String thresholdLimit, final boolean canRunOnFailed) {
super(threshold, newThreshold, failureThreshold, newFailureThreshold,
healthy, unHealthy, thresholdLimit, canRunOnFailed, "PMD");
public PmdReporter(final String healthy, final String unHealthy, final String thresholdLimit,
final String unstableTotalAll, final String unstableTotalHigh, final String unstableTotalNormal, final String unstableTotalLow,
final String unstableNewAll, final String unstableNewHigh, final String unstableNewNormal, final String unstableNewLow,
final String failedTotalAll, final String failedTotalHigh, final String failedTotalNormal, final String failedTotalLow,
final String failedNewAll, final String failedNewHigh, final String failedNewNormal, final String failedNewLow,
final boolean canRunOnFailed) {
super(healthy, unHealthy, thresholdLimit,
unstableTotalAll, unstableTotalHigh, unstableTotalNormal, unstableTotalLow,
unstableNewAll, unstableNewHigh, unstableNewNormal, unstableNewLow,
failedTotalAll, failedTotalHigh, failedTotalNormal, failedTotalLow,
failedNewAll, failedNewHigh, failedNewNormal, failedNewLow,
canRunOnFailed, "PMD");
}
// CHECKSTYLE:ON

Expand Down

0 comments on commit 3464ac5

Please sign in to comment.