Skip to content
This repository has been archived by the owner. It is now read-only.
Permalink
Browse files
[FIXED JENKINS-23446] Added aggregation action for matrix projects.
  • Loading branch information
uhafner committed Sep 24, 2014
1 parent 4f2bbc2 commit ab2228e05e2e2a71e88d56bed0bcf5a02bbfada5
Showing with 12 additions and 0 deletions.
  1. +12 −0 src/main/java/hudson/plugins/warnings/WarningsAnnotationsAggregator.java
@@ -13,6 +13,7 @@

import hudson.model.BuildListener;

import hudson.plugins.analysis.core.BuildHistory;
import hudson.plugins.analysis.core.HealthDescriptor;
import hudson.plugins.analysis.core.ParserResult;

@@ -69,10 +70,21 @@ public boolean endRun(final MatrixRun run) throws InterruptedException, IOExcept
aggregation.addAnnotations(result.getAnnotations());
aggregation.addModules(result.getModules());
}
createTotalsAction();
}
return true;
}

private void createTotalsAction() {
ParserResult totals = new ParserResult();
for (ParserResult result : totalsPerParser.values()) {
totals.addProject(result);
}
BuildHistory history = new BuildHistory(build, AggregatedWarningsResultAction.class, useStableBuildAsReference);
AggregatedWarningsResult result = new AggregatedWarningsResult(build, history, totals, defaultEncoding);
build.getActions().add(new AggregatedWarningsResultAction(build, result));
}

@Override
public boolean endBuild() throws InterruptedException, IOException {
for (String parser : totalsPerParser.keySet()) {

0 comments on commit ab2228e

Please sign in to comment.