Return-Path: X-Original-To: apmail-hadoop-common-commits-archive@www.apache.org Delivered-To: apmail-hadoop-common-commits-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 991B718201 for ; Tue, 16 Jun 2015 18:41:39 +0000 (UTC) Received: (qmail 5821 invoked by uid 500); 16 Jun 2015 18:41:22 -0000 Delivered-To: apmail-hadoop-common-commits-archive@hadoop.apache.org Received: (qmail 5242 invoked by uid 500); 16 Jun 2015 18:41:21 -0000 Mailing-List: contact common-commits-help@hadoop.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: common-dev@hadoop.apache.org Delivered-To: mailing list common-commits@hadoop.apache.org Received: (qmail 4139 invoked by uid 99); 16 Jun 2015 18:41:21 -0000 Received: from git1-us-west.apache.org (HELO git1-us-west.apache.org) (140.211.11.23) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 16 Jun 2015 18:41:21 +0000 Received: by git1-us-west.apache.org (ASF Mail Server at git1-us-west.apache.org, from userid 33) id 3C77BE3C4C; Tue, 16 Jun 2015 18:41:21 +0000 (UTC) Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: arp@apache.org To: common-commits@hadoop.apache.org Date: Tue, 16 Jun 2015 18:41:53 -0000 Message-Id: In-Reply-To: References: X-Mailer: ASF-Git Admin Mailer Subject: [34/50] [abbrv] hadoop git commit: HADOOP-12074. in Shell.java#runCommand() rethrow InterruptedException as InterruptedIOException (Contributed by Lavkesh Lahngir) HADOOP-12074. in Shell.java#runCommand() rethrow InterruptedException as InterruptedIOException (Contributed by Lavkesh Lahngir) Project: http://git-wip-us.apache.org/repos/asf/hadoop/repo Commit: http://git-wip-us.apache.org/repos/asf/hadoop/commit/95c73d49 Tree: http://git-wip-us.apache.org/repos/asf/hadoop/tree/95c73d49 Diff: http://git-wip-us.apache.org/repos/asf/hadoop/diff/95c73d49 Branch: refs/heads/HDFS-7240 Commit: 95c73d49b1bb459b626a9ac52acadb8f5fa724de Parents: 5583f88 Author: Vinayakumar B Authored: Thu Jun 11 11:51:14 2015 +0530 Committer: Vinayakumar B Committed: Thu Jun 11 11:51:14 2015 +0530 ---------------------------------------------------------------------- hadoop-common-project/hadoop-common/CHANGES.txt | 3 +++ .../src/main/java/org/apache/hadoop/util/Shell.java | 5 ++++- 2 files changed, 7 insertions(+), 1 deletion(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/hadoop/blob/95c73d49/hadoop-common-project/hadoop-common/CHANGES.txt ---------------------------------------------------------------------- diff --git a/hadoop-common-project/hadoop-common/CHANGES.txt b/hadoop-common-project/hadoop-common/CHANGES.txt index 134c834..4df6112 100644 --- a/hadoop-common-project/hadoop-common/CHANGES.txt +++ b/hadoop-common-project/hadoop-common/CHANGES.txt @@ -849,6 +849,9 @@ Release 2.8.0 - UNRELEASED HADOOP-7817. RawLocalFileSystem.append() should give FSDataOutputStream with accurate .getPos() (kanaka kumar avvaru via vinayakumarb) + HADOOP-12074. in Shell.java#runCommand() rethrow InterruptedException as + InterruptedIOException (Lavkesh Lahngir via vinayakumarb) + Release 2.7.1 - UNRELEASED INCOMPATIBLE CHANGES http://git-wip-us.apache.org/repos/asf/hadoop/blob/95c73d49/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/util/Shell.java ---------------------------------------------------------------------- diff --git a/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/util/Shell.java b/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/util/Shell.java index c76c921..45c1588 100644 --- a/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/util/Shell.java +++ b/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/util/Shell.java @@ -22,6 +22,7 @@ import java.io.File; import java.io.IOException; import java.io.InputStreamReader; import java.io.InputStream; +import java.io.InterruptedIOException; import java.nio.charset.Charset; import java.util.Arrays; import java.util.Map; @@ -554,7 +555,9 @@ abstract public class Shell { throw new ExitCodeException(exitCode, errMsg.toString()); } } catch (InterruptedException ie) { - throw new IOException(ie.toString()); + InterruptedIOException iie = new InterruptedIOException(ie.toString()); + iie.initCause(ie); + throw iie; } finally { if (timeOutTimer != null) { timeOutTimer.cancel();