HADOOP-11257. Update "hadoop jar" documentation to warn against using it for launching yarn jars (iwasakims via cmccabe)

This commit is contained in:
Colin Patrick Mccabe 2014-11-26 13:42:07 -08:00
parent a9adc1295c
commit 8f98225418
4 changed files with 18 additions and 0 deletions

View File

@ -110,6 +110,9 @@ Release 2.7.0 - UNRELEASED
HADOOP-11300. KMS startup scripts must not display the keystore / HADOOP-11300. KMS startup scripts must not display the keystore /
truststore passwords. (Arun Suresh via wang) truststore passwords. (Arun Suresh via wang)
HADOOP-11257. Update "hadoop jar" documentation to warn against using it
for launching yarn jars (iwasakims via cmccabe)
Release 2.6.0 - 2014-11-18 Release 2.6.0 - 2014-11-18
INCOMPATIBLE CHANGES INCOMPATIBLE CHANGES

View File

@ -31,6 +31,8 @@ function print_usage(){
echo " fs run a generic filesystem user client" echo " fs run a generic filesystem user client"
echo " version print the version" echo " version print the version"
echo " jar <jar> run a jar file" echo " jar <jar> run a jar file"
echo " note: please use \"yarn jar\" to launch"
echo " YARN applications, not this command."
echo " checknative [-a|-h] check native hadoop and compression libraries availability" echo " checknative [-a|-h] check native hadoop and compression libraries availability"
echo " distcp <srcurl> <desturl> copy file or directories recursively" echo " distcp <srcurl> <desturl> copy file or directories recursively"
echo " archive -archiveName NAME -p <parent path> <src>* <dest> create a hadoop archive" echo " archive -archiveName NAME -p <parent path> <src>* <dest> create a hadoop archive"
@ -101,6 +103,9 @@ case $COMMAND in
CLASS=org.apache.hadoop.util.VersionInfo CLASS=org.apache.hadoop.util.VersionInfo
elif [ "$COMMAND" = "jar" ] ; then elif [ "$COMMAND" = "jar" ] ; then
CLASS=org.apache.hadoop.util.RunJar CLASS=org.apache.hadoop.util.RunJar
if [[ -n "${YARN_OPTS}" ]] || [[ -n "${YARN_CLIENT_OPTS}" ]]; then
echo "WARNING: Use \"yarn jar\" to launch YARN applications."
fi
elif [ "$COMMAND" = "key" ] ; then elif [ "$COMMAND" = "key" ] ; then
CLASS=org.apache.hadoop.crypto.key.KeyShell CLASS=org.apache.hadoop.crypto.key.KeyShell
elif [ "$COMMAND" = "checknative" ] ; then elif [ "$COMMAND" = "checknative" ] ; then

View File

@ -161,6 +161,11 @@ call :updatepath %HADOOP_BIN_PATH%
goto :eof goto :eof
:jar :jar
if defined YARN_OPTS (
@echo WARNING: Use "yarn jar" to launch YARN applications.
) else if defined YARN_CLIENT_OPTS (
@echo WARNING: Use "yarn jar" to launch YARN applications.
)
set CLASS=org.apache.hadoop.util.RunJar set CLASS=org.apache.hadoop.util.RunJar
goto :eof goto :eof
@ -241,6 +246,8 @@ call :updatepath %HADOOP_BIN_PATH%
goto :MakeCmdArgsLoop goto :MakeCmdArgsLoop
:EndLoop :EndLoop
set hadoop-command-arguments=%_arguments% set hadoop-command-arguments=%_arguments%
@echo note: please use "yarn jar" to launch
@echo YARN applications, not this command.
goto :eof goto :eof
:print_usage :print_usage

View File

@ -177,6 +177,9 @@ User Commands
Word count example is also run using jar command. It can be referred from Word count example is also run using jar command. It can be referred from
Wordcount example Wordcount example
Use {{{../../hadoop-yarn/hadoop-yarn-site/YarnCommands.html#jar}<<<yarn jar>>>}}
to launch YARN applications instead.
* <<<job>>> * <<<job>>>
Deprecated. Use Deprecated. Use