Skip to content
Browse files

[FIXED JENKINS-25074] Make sure to call Job.getBuildHealthReports jus…

…t once per t:buildHealth render.
  • Loading branch information
jglick committed Oct 9, 2014
1 parent 9c96f3d commit f463abbe53488747725ea2e45dfc4a98ada02b8e
Showing with 6 additions and 2 deletions.
  1. +3 −0 changelog.html
  2. +3 −2 core/src/main/resources/lib/hudson/buildHealth.jelly
@@ -55,6 +55,9 @@
<!-- Record your changes in the trunk here. -->
<div id="trunk" style="display:none"><!--=TRUNK-BEGIN=-->
<ul class=image>
<li class=bug>
Build health computed repeatedly for a single Weather column cell.
(<a href="">issue 25074</a>)
<li class=rfe>
Missing workspace page should use 404 status code.
(<a href="">issue 10450</a>)
@@ -31,8 +31,9 @@ THE SOFTWARE.
<?jelly escape-by-default='true'?>
<j:jelly xmlns:j="jelly:core" xmlns:x="jelly:xml" xmlns:st="jelly:stapler" xmlns:d="jelly:define" xmlns:l="/lib/layout" xmlns:t="/lib/hudson" xmlns:f="/lib/form">
<j:set var="buildHealth" value="${job.buildHealth}"/>
<j:set var="healthReports" value="${job.buildHealthReports}"/>
<j:new var="emptyHealthReport" className="hudson.model.HealthReport"/>
<j:set var="buildHealth" value="${empty(healthReports) ? emptyHealthReport : healthReports[0]}"/>
<j:if test="${td}"><j:set var="useTdElement" value="x"/></j:if>
<x:element name="${useTdElement!=null?'td':'div'}">
<x:attribute name="data">${buildHealth.score}</x:attribute>
@@ -74,7 +75,7 @@ THE SOFTWARE.
<j:forEach var="rpt" items="${job.buildHealthReports}">
<j:forEach var="rpt" items="${healthReports}">
<td align="left">
<l:icon class="${rpt.iconClassName} icon-sm" />

0 comments on commit f463abb

Please sign in to comment.