Apache Solr open-source search software
SOLR-7831: Start Scripts: Allow a configurable stack size [-Xss]
Mark Robert Milleraf2bce9ee1a6
diff --git a/solr/CHANGES.txt b/solr/CHANGES.txtindex f3902953f49..620a4f161c4 100644--- a/solr/CHANGES.txt+++ b/solr/CHANGES.txt@@ -72,7 +72,11 @@ Other Changes(Xu Zhang, Per Steffensen, Ramkumar Aiyengar, Mark Miller)================== 5.4.0 ==================-(No Changes)++Other Changes+----------------------++* SOLR-7831: Start Scripts: Allow a configurable stack size [-Xss] (Steve Davids via Mark Miller)================== 5.3.0 ==================diff --git a/solr/bin/solr b/solr/bin/solrindex c0a84e65f17..7a632b23a02 100755--- a/solr/bin/solr+++ b/solr/bin/solr@@ -1289,7 +1289,7 @@ function launch_solr() {exit 1fi- SOLR_START_OPTS=('-server' '-Xss256k' "${JAVA_MEM_OPTS[@]}" "${GC_TUNE[@]}" "${GC_LOG_OPTS[@]}" \+ SOLR_START_OPTS=('-server' "${JAVA_MEM_OPTS[@]}" "${GC_TUNE[@]}" "${GC_LOG_OPTS[@]}" \"${REMOTE_JMX_OPTS[@]}" "${CLOUD_MODE_OPTS[@]}" \"-Djetty.port=$SOLR_PORT" "-DSTOP.PORT=$stop_port" "-DSTOP.KEY=$STOP_KEY" \"${SOLR_HOST_ARG[@]}" "-Duser.timezone=$SOLR_TIMEZONE" \diff --git a/solr/bin/solr.cmd b/solr/bin/solr.cmdindex b6cd308109c..0cef348dbda 100644--- a/solr/bin/solr.cmd+++ b/solr/bin/solr.cmd@@ -884,10 +884,10 @@ IF "%FG%"=="1" (REM run solr in the foregroundtitle "Solr-%SOLR_PORT%"echo %SOLR_PORT%>"%SOLR_TIP%"\bin\solr-%SOLR_PORT%.port- "%JAVA%" %SERVEROPT% -Xss256k %SOLR_JAVA_MEM% %START_OPTS% %GCLOG_OPT%:"!SOLR_LOGS_DIR!"/solr_gc.log -Dlog4j.configuration="%LOG4J_CONFIG%" -DSTOP.PORT=!STOP_PORT! -DSTOP.KEY=%STOP_KEY% ^+ "%JAVA%" %SERVEROPT% %SOLR_JAVA_MEM% %START_OPTS% %GCLOG_OPT%:"!SOLR_LOGS_DIR!"/solr_gc.log -Dlog4j.configuration="%LOG4J_CONFIG%" -DSTOP.PORT=!STOP_PORT! -DSTOP.KEY=%STOP_KEY% ^-Djetty.port=%SOLR_PORT% -Dsolr.solr.home="%SOLR_HOME%" -Dsolr.install.dir="%SOLR_TIP%" -Djetty.home="%SOLR_SERVER_DIR%" -Djava.io.tmpdir="%SOLR_SERVER_DIR%\tmp" -jar start.jar "%SOLR_JETTY_CONFIG%") ELSE (- START /B "Solr-%SOLR_PORT%" /D "%SOLR_SERVER_DIR%" "%JAVA%" %SERVEROPT% -Xss256k %SOLR_JAVA_MEM% %START_OPTS% %GCLOG_OPT%:"!SOLR_LOGS_DIR!"/solr_gc.log -Dlog4j.configuration="%LOG4J_CONFIG%" -DSTOP.PORT=!STOP_PORT! -DSTOP.KEY=%STOP_KEY% ^+ START /B "Solr-%SOLR_PORT%" /D "%SOLR_SERVER_DIR%" "%JAVA%" %SERVEROPT% %SOLR_JAVA_MEM% %START_OPTS% %GCLOG_OPT%:"!SOLR_LOGS_DIR!"/solr_gc.log -Dlog4j.configuration="%LOG4J_CONFIG%" -DSTOP.PORT=!STOP_PORT! -DSTOP.KEY=%STOP_KEY% ^-Djetty.port=%SOLR_PORT% -Dsolr.solr.home="%SOLR_HOME%" -Dsolr.install.dir="%SOLR_TIP%" -Djetty.home="%SOLR_SERVER_DIR%" -Djava.io.tmpdir="%SOLR_SERVER_DIR%\tmp" -jar start.jar "%SOLR_JETTY_CONFIG%" > "!SOLR_LOGS_DIR!\solr-%SOLR_PORT%-console.log"echo %SOLR_PORT%>"%SOLR_TIP%"\bin\solr-%SOLR_PORT%.portdiff --git a/solr/bin/solr.in.cmd b/solr/bin/solr.in.cmdindex e97e0b29687..0b299af2890 100644--- a/solr/bin/solr.in.cmd+++ b/solr/bin/solr.in.cmd@@ -66,6 +66,9 @@ set ENABLE_REMOTE_JMX_OPTS=falseREM The script will use SOLR_PORT+10000 for the RMI_PORT or you can set it hereREM set RMI_PORT=18983+REM Set the thread stack size+set SOLR_OPTS=%SOLR_OPTS% -Xss256k+REM Anything you add to the SOLR_OPTS variable will be included in the javaREM start command line as-is, in ADDITION to other options. If you specify theREM -a option on start script, those options will be appended as well. Examples:@@ -93,5 +96,5 @@ REM Uncomment if you want to override previously defined SSL values for HTTP cliREM otherwise keep them commented and the above values will automatically be set for HTTP clientsREM set SOLR_SSL_CLIENT_KEY_STORE=REM set SOLR_SSL_CLIENT_KEY_STORE_PASSWORD=-REM setSOLR_SSL_CLIENT_TRUST_STORE=+REM set SOLR_SSL_CLIENT_TRUST_STORE=REM setSOLR_SSL_CLIENT_TRUST_STORE_PASSWORD=\ No newline at end of filediff --git a/solr/bin/solr.in.sh b/solr/bin/solr.in.shindex b55552fa9c4..150f6c277d3 100644--- a/solr/bin/solr.in.sh+++ b/solr/bin/solr.in.sh@@ -68,6 +68,9 @@ ENABLE_REMOTE_JMX_OPTS="false"# The script will use SOLR_PORT+10000 for the RMI_PORT or you can set it here# RMI_PORT=18983+# Set the thread stack size+SOLR_OPTS="$SOLR_OPTS -Xss256k"+# Anything you add to the SOLR_OPTS variable will be included in the java# start command line as-is, in ADDITION to other options. If you specify the# -a option on start script, those options will be appended as well. Examples: