Skip to content

Commit 0ee7cd3

Browse files
committed
move usejavacp opt to spark-shell
1 parent 353684c commit 0ee7cd3

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

bin/spark-class

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -107,8 +107,7 @@ else
107107
fi
108108

109109
# Set JAVA_OPTS to be able to load native libraries and to set heap size
110-
# SPARK-3936: scala does not assume use of the java classpath, so we need to add the "-Dscala.usejavacp=true"
111-
JAVA_OPTS="-Dscala.usejavacp=true -XX:MaxPermSize=128m $OUR_JAVA_OPTS"
110+
JAVA_OPTS="-XX:MaxPermSize=128m $OUR_JAVA_OPTS"
112111
JAVA_OPTS="$JAVA_OPTS -Xms$OUR_JAVA_MEM -Xmx$OUR_JAVA_MEM"
113112

114113
# Load extra JAVA_OPTS from conf/java-opts, if it exists

bin/spark-shell

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,9 @@ source $FWDIR/bin/utils.sh
4545
SUBMIT_USAGE_FUNCTION=usage
4646
gatherSparkSubmitOpts "$@"
4747

48+
# SPARK-4161: scala does not assume use of the java classpath, so we need to add the "-Dscala.usejavacp=true"
49+
SPARK_SUBMIT_OPTS="$SPARK_SUBMIT_OPTS -Dscala.usejavacp=true"
50+
4851
function main() {
4952
if $cygwin; then
5053
# Workaround for issue involving JLine and Cygwin

0 commit comments

Comments
 (0)