From 617bbb531e3d88f4a3ac10cc9d77bd33223e38d4 Mon Sep 17 00:00:00 2001 From: Raihaan Shouhell Date: Sat, 28 Sep 2019 04:59:03 +0800 Subject: [PATCH] Update the minimum required Remoting version to 3.14 (#4208) * Let remoting handle missing channels * Bump minimum remoting version to 3.14 --- core/src/main/java/hudson/Launcher.java | 6 +----- pom.xml | 2 +- 2 files changed, 2 insertions(+), 6 deletions(-) diff --git a/core/src/main/java/hudson/Launcher.java b/core/src/main/java/hudson/Launcher.java index 278d03c410..62dbc7c6e1 100644 --- a/core/src/main/java/hudson/Launcher.java +++ b/core/src/main/java/hudson/Launcher.java @@ -1327,11 +1327,7 @@ public abstract class Launcher { Channel taskChannel = null; try { // Sync IO will fail automatically if the channel is being closed, no need to use getOpenChannelOrFail() - // TODOL Replace by Channel#currentOrFail() when Remoting version allows - taskChannel = Channel.current(); - if (taskChannel == null) { - throw new IOException("No Remoting channel associated with this thread"); - } + taskChannel = Channel.currentOrFail(); taskChannel.syncIO(); } catch (Throwable t) { // this includes a failure to sync, agent.jar too old, etc diff --git a/pom.xml b/pom.xml index c701a0736e..5827b0bf6e 100755 --- a/pom.xml +++ b/pom.xml @@ -105,7 +105,7 @@ THE SOFTWARE. 3.35 - 3.4 + 3.14 Max -- GitLab