You are viewing a plain text version of this content. The canonical link for it is here.
Posted to common-commits@hadoop.apache.org by jb...@apache.org on 2020/11/16 21:42:49 UTC

[hadoop] branch branch-3.1 updated: YARN-10485. TimelineConnector swallows InterruptedException (#2450). Contributed by Ahmed Hussein

This is an automated email from the ASF dual-hosted git repository.

jbrennan pushed a commit to branch branch-3.1
in repository https://gitbox.apache.org/repos/asf/hadoop.git


The following commit(s) were added to refs/heads/branch-3.1 by this push:
     new de9f778  YARN-10485. TimelineConnector swallows InterruptedException (#2450). Contributed by Ahmed Hussein
de9f778 is described below

commit de9f77875082a2eef0d8f71edeebe0c2f88229d8
Author: Ahmed Hussein <50...@users.noreply.github.com>
AuthorDate: Mon Nov 16 14:55:40 2020 -0600

    YARN-10485. TimelineConnector swallows InterruptedException (#2450). Contributed by Ahmed Hussein
    
    (cherry picked from commit 0b2510ee1fb2c92d3b7d2b2183e532b7637d93b9)
---
 hadoop-yarn-project/hadoop-yarn/hadoop-yarn-common/pom.xml            | 1 -
 .../org/apache/hadoop/yarn/client/api/impl/TimelineConnector.java     | 4 +++-
 2 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-common/pom.xml b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-common/pom.xml
index 4bf5366..792918f 100644
--- a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-common/pom.xml
+++ b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-common/pom.xml
@@ -41,7 +41,6 @@
       <scope>provided</scope>
     </dependency>
 
-
     <!-- 'mvn dependency:analyze' fails to detect use of this dependency -->
     <dependency>
       <groupId>org.apache.hadoop</groupId>
diff --git a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-common/src/main/java/org/apache/hadoop/yarn/client/api/impl/TimelineConnector.java b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-common/src/main/java/org/apache/hadoop/yarn/client/api/impl/TimelineConnector.java
index 9d084d7..2b43b6c 100644
--- a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-common/src/main/java/org/apache/hadoop/yarn/client/api/impl/TimelineConnector.java
+++ b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-common/src/main/java/org/apache/hadoop/yarn/client/api/impl/TimelineConnector.java
@@ -19,6 +19,7 @@
 package org.apache.hadoop.yarn.client.api.impl;
 
 import java.io.IOException;
+import java.io.InterruptedIOException;
 import java.lang.reflect.UndeclaredThrowableException;
 import java.net.ConnectException;
 import java.net.HttpURLConnection;
@@ -351,7 +352,8 @@ public class TimelineConnector extends AbstractService {
           // sleep for the given time interval
           Thread.sleep(retryInterval);
         } catch (InterruptedException ie) {
-          LOG.warn("Client retry sleep interrupted! ");
+          Thread.currentThread().interrupt();
+          throw new InterruptedIOException("Client retry sleep interrupted!");
         }
       }
       throw new RuntimeException("Failed to connect to timeline server. "


---------------------------------------------------------------------
To unsubscribe, e-mail: common-commits-unsubscribe@hadoop.apache.org
For additional commands, e-mail: common-commits-help@hadoop.apache.org