зеркало из https://github.com/microsoft/spark.git
support customized java options for master, worker, executor, repl shell
This commit is contained in:
Родитель
a9cfac347a
Коммит
858784459f
20
run
20
run
|
@ -25,6 +25,26 @@ if [ "$1" = "spark.deploy.master.Master" -o "$1" = "spark.deploy.worker.Worker"
|
|||
SPARK_JAVA_OPTS=$SPARK_DAEMON_JAVA_OPTS # Empty by default
|
||||
fi
|
||||
|
||||
|
||||
# Add java opts for master, worker, executor. The opts maybe null
|
||||
case "$1" in
|
||||
'spark.deploy.master.Master')
|
||||
SPARK_JAVA_OPTS+=" $SPARK_MASTER_OPTS"
|
||||
;;
|
||||
'spark.deploy.worker.Worker')
|
||||
SPARK_JAVA_OPTS+=" $SPARK_WORKER_OPTS"
|
||||
;;
|
||||
'spark.executor.StandaloneExecutorBackend')
|
||||
SPARK_JAVA_OPTS+=" $SPARK_EXECUTOR_OPTS"
|
||||
;;
|
||||
'spark.executor.MesosExecutorBackend')
|
||||
SPARK_JAVA_OPTS+=" $SPARK_EXECUTOR_OPTS"
|
||||
;;
|
||||
'spark.repl.Main')
|
||||
SPARK_JAVA_OPTS+=" $SPARK_REPL_OPTS"
|
||||
;;
|
||||
esac
|
||||
|
||||
if [ "$SPARK_LAUNCH_WITH_SCALA" == "1" ]; then
|
||||
if [ `command -v scala` ]; then
|
||||
RUNNER="scala"
|
||||
|
|
Загрузка…
Ссылка в новой задаче