Skip to content

Commit 0b2510e

Browse files
authored
YARN-10485. TimelineConnector swallows InterruptedException (#2450). Contributed by Ahmed Hussein
1 parent dd85a90 commit 0b2510e

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

hadoop-yarn-project/hadoop-yarn/hadoop-yarn-common/pom.xml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,6 @@
4545
<artifactId>hadoop-hdfs-client</artifactId>
4646
</dependency>
4747

48-
4948
<!-- 'mvn dependency:analyze' fails to detect use of this dependency -->
5049
<dependency>
5150
<groupId>org.apache.hadoop</groupId>

hadoop-yarn-project/hadoop-yarn/hadoop-yarn-common/src/main/java/org/apache/hadoop/yarn/client/api/impl/TimelineConnector.java

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@
1919
package org.apache.hadoop.yarn.client.api.impl;
2020

2121
import java.io.IOException;
22+
import java.io.InterruptedIOException;
2223
import java.lang.reflect.UndeclaredThrowableException;
2324
import java.net.ConnectException;
2425
import java.net.HttpURLConnection;
@@ -361,7 +362,8 @@ public Object retryOn(TimelineClientRetryOp op)
361362
// sleep for the given time interval
362363
Thread.sleep(retryInterval);
363364
} catch (InterruptedException ie) {
364-
LOG.warn("Client retry sleep interrupted! ");
365+
Thread.currentThread().interrupt();
366+
throw new InterruptedIOException("Client retry sleep interrupted!");
365367
}
366368
}
367369
throw new RuntimeException("Failed to connect to timeline server. "

0 commit comments

Comments
 (0)