aboutsummaryrefslogtreecommitdiff
path: root/bin
diff options
context:
space:
mode:
authorWangTaoTheTonic <barneystinson@aliyun.com>2014-10-01 15:15:09 -0700
committerMichael Armbrust <michael@databricks.com>2014-10-01 15:15:24 -0700
commitd61f2c15bb22253bfdda77462b1bd383987d2f5a (patch)
treea1e90441252ab3d670e76b5139d020837d18f33a /bin
parentfcad3fae6135bc2c9bdaf9e4c3cfe24838e63eae (diff)
downloadspark-d61f2c15bb22253bfdda77462b1bd383987d2f5a.tar.gz
spark-d61f2c15bb22253bfdda77462b1bd383987d2f5a.tar.bz2
spark-d61f2c15bb22253bfdda77462b1bd383987d2f5a.zip
[SPARK-3658][SQL] Start thrift server as a daemon
https://issues.apache.org/jira/browse/SPARK-3658 And keep the `CLASS_NOT_FOUND_EXIT_STATUS` and exit message in `SparkSubmit.scala`. Author: WangTaoTheTonic <barneystinson@aliyun.com> Author: WangTao <barneystinson@aliyun.com> Closes #2509 from WangTaoTheTonic/thriftserver and squashes the following commits: 5dcaab2 [WangTaoTheTonic] issue about coupling 8ad9f95 [WangTaoTheTonic] generalization 598e21e [WangTao] take thrift server as a daemon
Diffstat (limited to 'bin')
-rwxr-xr-xbin/spark-sql12
1 files changed, 1 insertions, 11 deletions
diff --git a/bin/spark-sql b/bin/spark-sql
index 9d66140b6a..63d00437d5 100755
--- a/bin/spark-sql
+++ b/bin/spark-sql
@@ -24,7 +24,6 @@
set -o posix
CLASS="org.apache.spark.sql.hive.thriftserver.SparkSQLCLIDriver"
-CLASS_NOT_FOUND_EXIT_STATUS=101
# Figure out where Spark is installed
FWDIR="$(cd "`dirname "$0"`"/..; pwd)"
@@ -53,13 +52,4 @@ source "$FWDIR"/bin/utils.sh
SUBMIT_USAGE_FUNCTION=usage
gatherSparkSubmitOpts "$@"
-"$FWDIR"/bin/spark-submit --class $CLASS "${SUBMISSION_OPTS[@]}" spark-internal "${APPLICATION_OPTS[@]}"
-exit_status=$?
-
-if [[ exit_status -eq CLASS_NOT_FOUND_EXIT_STATUS ]]; then
- echo
- echo "Failed to load Spark SQL CLI main class $CLASS."
- echo "You need to build Spark with -Phive."
-fi
-
-exit $exit_status
+exec "$FWDIR"/bin/spark-submit --class $CLASS "${SUBMISSION_OPTS[@]}" spark-internal "${APPLICATION_OPTS[@]}"