From 97cffbe2e421d4e847ec91223cb995342319ac70 Mon Sep 17 00:00:00 2001 From: Thomas Suckow Date: Fri, 15 May 2015 08:49:22 -0700 Subject: [PATCH 1/4] [FIXED JENKINS-28425] Fix build history styling badness --- war/src/main/webapp/css/style.css | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/war/src/main/webapp/css/style.css b/war/src/main/webapp/css/style.css index 534a2effc1..a625cdb3d8 100644 --- a/war/src/main/webapp/css/style.css +++ b/war/src/main/webapp/css/style.css @@ -982,6 +982,7 @@ table.parameters > tbody:hover { .build-row-cell .pane.build-name { width: 25%; font-weight: bold; + vertical-align: top; } .build-row-cell .pane.build-details { width: 50%; @@ -1066,7 +1067,7 @@ table.parameters > tbody:hover { .build-row-cell .pane.build-name .display-name, .build-row-cell .indent-multiline { - margin-left: 20px !important; /* Sync changes with func expandControlsTo50Percent in hudson-behavior.js */ + padding-left: 20px !important; /* Sync changes with func expandControlsTo50Percent in hudson-behavior.js */ } .build-row .build-row-cell { From 69a9938739d086d377e8ddda2ec8d611508602ec Mon Sep 17 00:00:00 2001 From: tfennelly Date: Mon, 18 May 2015 15:35:51 +0100 Subject: [PATCH 2/4] Noting 28425 --- changelog.html | 3 +++ 1 file changed, 3 insertions(+) diff --git a/changelog.html b/changelog.html index 111ec064bd..02ebd955fc 100644 --- a/changelog.html +++ b/changelog.html @@ -70,6 +70,9 @@ Upcoming changes
  • Do not follow href after sending POST via l:task (issue 28437) +
  • + Build history overflows + (issue 28425)

    What's new in 1.613 (2015/05/10)

    From db5f80597b7b11418413390227135eac23a6beac Mon Sep 17 00:00:00 2001 From: Andre Miranda Date: Mon, 18 May 2015 13:54:36 -0300 Subject: [PATCH 3/4] Fix ptBR translation --- core/src/main/resources/hudson/model/Messages_pt_BR.properties | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/src/main/resources/hudson/model/Messages_pt_BR.properties b/core/src/main/resources/hudson/model/Messages_pt_BR.properties index a095bef6dd..b84852a2be 100644 --- a/core/src/main/resources/hudson/model/Messages_pt_BR.properties +++ b/core/src/main/resources/hudson/model/Messages_pt_BR.properties @@ -511,7 +511,7 @@ AbstractProject.LabelLink=Slaves em label: {2} # Artifacts of {0} {1} Run.ArtifactsBrowserTitle=Artefatos de {0} {1} # Build with Parameters -AbstractProject.build_with_parameters=Constru\u00eddo com par\u00e2metros +AbstractProject.build_with_parameters=Construir com par\u00e2metros # Still unstable ResultTrend.StillUnstable=Ainda inst\u00e1vel # Running as {0} From bb7a479c7e5912b1b11537faf6c889e678cfff09 Mon Sep 17 00:00:00 2001 From: David Hoover Date: Fri, 15 May 2015 12:41:30 -0700 Subject: [PATCH 4/4] Use ConsistentHash's mass-add method. Calling hash.add() in a tight loop gets very expensive. With a good-sized queue & slave pool, this cost tens of seconds, but now it costs tens of milliseconds. --- core/src/main/java/hudson/model/LoadBalancer.java | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/core/src/main/java/hudson/model/LoadBalancer.java b/core/src/main/java/hudson/model/LoadBalancer.java index 915abf26cb..a0403e1b97 100644 --- a/core/src/main/java/hudson/model/LoadBalancer.java +++ b/core/src/main/java/hudson/model/LoadBalancer.java @@ -23,6 +23,7 @@ */ package hudson.model; +import com.google.common.collect.Maps; import hudson.Extension; import hudson.ExtensionPoint; import hudson.model.Queue.Task; @@ -34,6 +35,7 @@ import hudson.util.ConsistentHash.Hash; import java.util.ArrayList; import java.util.List; +import java.util.Map; /** * Strategy that decides which {@link Task} gets run on which {@link Executor}. @@ -84,8 +86,14 @@ public abstract class LoadBalancer implements ExtensionPoint { return node.getName(); } }); - for (ExecutorChunk ec : ws.works(i).applicableExecutorChunks()) - hash.add(ec,ec.size()*100); + + // Build a Map to pass in rather than repeatedly calling hash.add() because each call does lots of expensive work + List chunks = ws.works(i).applicableExecutorChunks(); + Map toAdd = Maps.newHashMapWithExpectedSize(chunks.size()); + for (ExecutorChunk ec : chunks) { + toAdd.put(ec, ec.size()*100); + } + hash.addAll(toAdd); hashes.add(hash); }