Skip to content

Commit

Permalink
DSP-19969 allow spark executor log to separate file
Browse files Browse the repository at this point in the history
  • Loading branch information
alexoss68 committed Dec 11, 2019
1 parent 4ad6b43 commit 88f7b0f
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 3 deletions.
11 changes: 9 additions & 2 deletions bin/manager_start.sh
Original file line number Diff line number Diff line change
Expand Up @@ -27,15 +27,22 @@ JAVA_OPTS="-XX:MaxDirectMemorySize=$MAX_DIRECT_MEMORY

MAIN="spark.jobserver.JobManager"

if [ "$SEPARATE_EXECUTOR_LOGGING" = "true" ]
then
export EXECUTOR_LOGGING_OPTS=""
else
export EXECUTOR_LOGGING_OPTS="$LOGGING_OPTS"
fi

if [ ! -z $3 ]; then
cmd='$SPARK_HOME/bin/spark-submit --class $MAIN --driver-memory $JOBSERVER_MEMORY
--conf "spark.executor.extraJavaOptions=$LOGGING_OPTS"
--conf "spark.executor.extraJavaOptions=$EXECUTOR_LOGGING_OPTS"
--proxy-user $3
--driver-java-options "$GC_OPTS $JAVA_OPTS $LOGGING_OPTS $CONFIG_OVERRIDES"
$appdir/spark-job-server.jar $1 $2 $conffile'
else
cmd='$SPARK_HOME/bin/spark-submit --class $MAIN --driver-memory $JOBSERVER_MEMORY
--conf "spark.executor.extraJavaOptions=$LOGGING_OPTS"
--conf "spark.executor.extraJavaOptions=$EXECUTOR_LOGGING_OPTS"
--driver-java-options "$GC_OPTS $JAVA_OPTS $LOGGING_OPTS $CONFIG_OVERRIDES"
$appdir/spark-job-server.jar $1 $2 $conffile'
fi
Expand Down
9 changes: 8 additions & 1 deletion bin/server_start.sh
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,15 @@ if [ -f "$PIDFILE" ] && kill -0 $(cat "$PIDFILE"); then
exit 1
fi

if [ "$SEPARATE_EXECUTOR_LOGGING" = "true" ]
then
export EXECUTOR_LOGGING_OPTS=""
else
export EXECUTOR_LOGGING_OPTS="$LOGGING_OPTS"
fi

cmd='$SPARK_HOME/bin/spark-submit --class $MAIN --driver-memory $JOBSERVER_MEMORY
--conf "spark.executor.extraJavaOptions=$LOGGING_OPTS"
--conf "spark.executor.extraJavaOptions=$EXECUTOR_LOGGING_OPTS"
--driver-java-options "$GC_OPTS $JAVA_OPTS $LOGGING_OPTS $CONFIG_OVERRIDES"
$@ $appdir/spark-job-server.jar $conffile'

Expand Down

0 comments on commit 88f7b0f

Please sign in to comment.