hadoop-common-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From vinayakum...@apache.org
Subject [25/45] hadoop git commit: HADOOP-11150. hadoop command should show the reason on failure by invalid COMMAND or CLASSNAME (Masatake Iwasaki via aw)
Date Mon, 17 Nov 2014 06:30:27 GMT
HADOOP-11150. hadoop command should show the reason on failure by invalid COMMAND or CLASSNAME
(Masatake Iwasaki via aw)


Project: http://git-wip-us.apache.org/repos/asf/hadoop/repo
Commit: http://git-wip-us.apache.org/repos/asf/hadoop/commit/aee68b67
Tree: http://git-wip-us.apache.org/repos/asf/hadoop/tree/aee68b67
Diff: http://git-wip-us.apache.org/repos/asf/hadoop/diff/aee68b67

Branch: refs/heads/HDFS-EC
Commit: aee68b67f3894e19757f6e4f3ffb6ca10b9a0d64
Parents: b650e61
Author: Allen Wittenauer <aw@apache.org>
Authored: Thu Nov 13 12:08:03 2014 -0800
Committer: Allen Wittenauer <aw@apache.org>
Committed: Thu Nov 13 12:08:03 2014 -0800

----------------------------------------------------------------------
 hadoop-common-project/hadoop-common/CHANGES.txt                   | 3 +++
 .../hadoop-common/src/main/bin/hadoop-functions.sh                | 3 +++
 2 files changed, 6 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/hadoop/blob/aee68b67/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 f3a0237..1a8c41d 100644
--- a/hadoop-common-project/hadoop-common/CHANGES.txt
+++ b/hadoop-common-project/hadoop-common/CHANGES.txt
@@ -138,6 +138,9 @@ Trunk (Unreleased)
     HADOOP-11025. hadoop-daemons.sh should just call hdfs directly (Masatake
     Iwasaki via aw)
 
+    HADOOP-11150. hadoop command should show the reason on failure by 
+    invalid COMMAND or CLASSNAME (Masatake Iwasaki via aw)
+
   BUG FIXES
 
     HADOOP-9451. Fault single-layer config if node group topology is enabled.

http://git-wip-us.apache.org/repos/asf/hadoop/blob/aee68b67/hadoop-common-project/hadoop-common/src/main/bin/hadoop-functions.sh
----------------------------------------------------------------------
diff --git a/hadoop-common-project/hadoop-common/src/main/bin/hadoop-functions.sh b/hadoop-common-project/hadoop-common/src/main/bin/hadoop-functions.sh
index 4f75a7c..b5d4b1c 100644
--- a/hadoop-common-project/hadoop-common/src/main/bin/hadoop-functions.sh
+++ b/hadoop-common-project/hadoop-common/src/main/bin/hadoop-functions.sh
@@ -286,6 +286,9 @@ function hadoop_validate_classname
   shift 1
 
   if [[ ! ${class} =~ \. ]]; then
+    # assuming the arg is typo of command if it does not conatain ".".
+    # class belonging to no package is not allowed as a result.
+    hadoop_error "ERROR: ${class} is not COMMAND nor fully qualified CLASSNAME."
     return 1
   fi
   return 0


Mime
View raw message