From 8f5bdcb414cd70227f7e768f8b23ddfc328250b0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Oliver=20Gond=C5=BEa?= Date: Mon, 13 Jul 2015 10:34:47 +0200 Subject: [PATCH 1/4] [FIXED JENKINS-29376] Rename help texts as well Amends eec43983a3bdfce6de45ca0559d8a9f8a1250b71. (cherry picked from commit 1c1d5a95d9d5aa86b5ae890942553fbcb0f1a641) --- .../{help-assignedLabelString.html => help-label.html} | 0 ...{help-assignedLabelString_zh_TW.html => help-label_zh_TW.html} | 0 2 files changed, 0 insertions(+), 0 deletions(-) rename core/src/main/resources/hudson/model/AbstractProject/{help-assignedLabelString.html => help-label.html} (100%) rename core/src/main/resources/hudson/model/AbstractProject/{help-assignedLabelString_zh_TW.html => help-label_zh_TW.html} (100%) diff --git a/core/src/main/resources/hudson/model/AbstractProject/help-assignedLabelString.html b/core/src/main/resources/hudson/model/AbstractProject/help-label.html similarity index 100% rename from core/src/main/resources/hudson/model/AbstractProject/help-assignedLabelString.html rename to core/src/main/resources/hudson/model/AbstractProject/help-label.html diff --git a/core/src/main/resources/hudson/model/AbstractProject/help-assignedLabelString_zh_TW.html b/core/src/main/resources/hudson/model/AbstractProject/help-label_zh_TW.html similarity index 100% rename from core/src/main/resources/hudson/model/AbstractProject/help-assignedLabelString_zh_TW.html rename to core/src/main/resources/hudson/model/AbstractProject/help-label_zh_TW.html From 132b915615bed822a14d751667c4a0842ed6ffa6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Oliver=20Gond=C5=BEa?= Date: Mon, 13 Jul 2015 09:07:30 +0200 Subject: [PATCH 2/4] [FIXED JENKINS-29286] Use byte size to sort disk space monitor columns (cherry picked from commit fabec0eef00212109a1ad5c2bedcb8c55de4f38a) --- .../node_monitors/DiskSpaceMonitorDescriptor.java | 10 ++++++++++ .../hudson/node_monitors/DiskSpaceMonitor/column.jelly | 4 ++-- .../hudson/node_monitors/SwapSpaceMonitor/column.jelly | 2 +- .../node_monitors/TemporarySpaceMonitor/column.jelly | 4 ++-- 4 files changed, 15 insertions(+), 5 deletions(-) diff --git a/core/src/main/java/hudson/node_monitors/DiskSpaceMonitorDescriptor.java b/core/src/main/java/hudson/node_monitors/DiskSpaceMonitorDescriptor.java index 4bd1c939c6..67d33c7227 100644 --- a/core/src/main/java/hudson/node_monitors/DiskSpaceMonitorDescriptor.java +++ b/core/src/main/java/hudson/node_monitors/DiskSpaceMonitorDescriptor.java @@ -37,6 +37,8 @@ import java.math.BigDecimal; import java.text.ParseException; import java.util.Locale; +import org.kohsuke.accmod.Restricted; +import org.kohsuke.accmod.restrictions.DoNotUse; import org.kohsuke.stapler.export.ExportedBean; import org.kohsuke.stapler.export.Exported; @@ -81,6 +83,14 @@ public abstract class DiskSpaceMonitorDescriptor extends AbstractAsyncNodeMonito return path; } + // Needed for jelly that does not seem to be able to access properties + // named 'size' as it confuses it with built-in size method and fails + // to parse the expression expecting '()'. + @Restricted(DoNotUse.class) + public long getFreeSize() { + return size; + } + /** * Gets GB left. */ diff --git a/core/src/main/resources/hudson/node_monitors/DiskSpaceMonitor/column.jelly b/core/src/main/resources/hudson/node_monitors/DiskSpaceMonitor/column.jelly index c71982967e..81a19eb0a9 100644 --- a/core/src/main/resources/hudson/node_monitors/DiskSpaceMonitor/column.jelly +++ b/core/src/main/resources/hudson/node_monitors/DiskSpaceMonitor/column.jelly @@ -29,7 +29,7 @@ THE SOFTWARE. N/A - + - \ No newline at end of file + diff --git a/core/src/main/resources/hudson/node_monitors/SwapSpaceMonitor/column.jelly b/core/src/main/resources/hudson/node_monitors/SwapSpaceMonitor/column.jelly index 5a817a5305..35fa757e79 100644 --- a/core/src/main/resources/hudson/node_monitors/SwapSpaceMonitor/column.jelly +++ b/core/src/main/resources/hudson/node_monitors/SwapSpaceMonitor/column.jelly @@ -32,4 +32,4 @@ THE SOFTWARE. - \ No newline at end of file + diff --git a/core/src/main/resources/hudson/node_monitors/TemporarySpaceMonitor/column.jelly b/core/src/main/resources/hudson/node_monitors/TemporarySpaceMonitor/column.jelly index ac42d83e35..5c1a410d1b 100644 --- a/core/src/main/resources/hudson/node_monitors/TemporarySpaceMonitor/column.jelly +++ b/core/src/main/resources/hudson/node_monitors/TemporarySpaceMonitor/column.jelly @@ -29,7 +29,7 @@ THE SOFTWARE. N/A - + - \ No newline at end of file + From b591a241b4a437863bf48ebbd6aa4d3f2c0f831c Mon Sep 17 00:00:00 2001 From: Stephen Connolly Date: Thu, 23 Apr 2015 10:17:50 +0100 Subject: [PATCH 3/4] [FIXED JENKINS-28058] Don't send a reference to Computer.class over remoting channels - Logging added to help diagnose was actually causing Jenkins.class to be initialized on the remoting side (cherry picked from commit df831325b6623c479dcf4b215415f4523d10530b) --- core/src/main/java/hudson/model/Computer.java | 19 ++++++++++++------- 1 file changed, 12 insertions(+), 7 deletions(-) diff --git a/core/src/main/java/hudson/model/Computer.java b/core/src/main/java/hudson/model/Computer.java index f3fa40a971..8612d6517e 100644 --- a/core/src/main/java/hudson/model/Computer.java +++ b/core/src/main/java/hudson/model/Computer.java @@ -1159,11 +1159,11 @@ public /*transient*/ abstract class Computer extends Actionable implements Acces try { InetAddress ia = InetAddress.getByName(address); if(!(ia instanceof Inet4Address)) { - LOGGER.fine(address+" is not an IPv4 address"); + LOGGER.log(Level.FINE, "{0} is not an IPv4 address", address); continue; } if(!ComputerPinger.checkIsReachable(ia, 3)) { - LOGGER.fine(address+" didn't respond to ping"); + LOGGER.log(Level.FINE, "{0} didn't respond to ping", address); continue; } cachedHostName = ia.getCanonicalHostName(); @@ -1171,7 +1171,10 @@ public /*transient*/ abstract class Computer extends Actionable implements Acces return cachedHostName; } catch (IOException e) { // if a given name fails to parse on this host, we get this error - LOGGER.log(Level.FINE, "Failed to parse "+address,e); + LogRecord lr = new LogRecord(Level.FINE, "Failed to parse {0}"); + lr.setThrown(e); + lr.setParameters(new Object[]{address}); + LOGGER.log(lr); } } @@ -1195,27 +1198,29 @@ public /*transient*/ abstract class Computer extends Actionable implements Acces } private static class ListPossibleNames extends MasterToSlaveCallable,IOException> { + private static final Logger LOGGER = Logger.getLogger(ListPossibleNames.class.getName()); + public List call() throws IOException { List names = new ArrayList(); Enumeration nis = NetworkInterface.getNetworkInterfaces(); while (nis.hasMoreElements()) { NetworkInterface ni = nis.nextElement(); - LOGGER.fine("Listing up IP addresses for "+ni.getDisplayName()); + LOGGER.log(Level.FINE, "Listing up IP addresses for {0}", ni.getDisplayName()); Enumeration e = ni.getInetAddresses(); while (e.hasMoreElements()) { InetAddress ia = e.nextElement(); if(ia.isLoopbackAddress()) { - LOGGER.fine(ia+" is a loopback address"); + LOGGER.log(Level.FINE, "{0} is a loopback address", ia); continue; } if(!(ia instanceof Inet4Address)) { - LOGGER.fine(ia+" is not an IPv4 address"); + LOGGER.log(Level.FINE, "{0} is not an IPv4 address", ia); continue; } - LOGGER.fine(ia+" is a viable candidate"); + LOGGER.log(Level.FINE, "{0} is a viable candidate", ia); names.add(ia.getHostAddress()); } } From 2906718ff53dd781a1248fff5dd56ac729438558 Mon Sep 17 00:00:00 2001 From: Stephen Connolly Date: Tue, 14 Jul 2015 15:22:15 +0100 Subject: [PATCH 4/4] [FIXED JENKINS-28844] The curious case of the Channel memory cycles Pick up the remoting 2.52 release (cherry picked from commit aac20468ff5511ea6c58de07f3bcf3ae108b9cb0) --- pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pom.xml b/pom.xml index 3d7334803e..5428993d62 100644 --- a/pom.xml +++ b/pom.xml @@ -176,7 +176,7 @@ THE SOFTWARE. org.jenkins-ci.main remoting - 2.50 + 2.52