You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucene.apache.org by ab...@apache.org on 2017/12/07 12:45:15 UTC
[21/50] [abbrv] lucene-solr:jira/solr-11285-sim: SOLR-9137: bin/solr
script ignored custom STOP_PORT on shutdown. (Joachim Kohlhammer, Steve Rowe,
Christine Poerschke)
SOLR-9137: bin/solr script ignored custom STOP_PORT on shutdown.
(Joachim Kohlhammer, Steve Rowe, Christine Poerschke)
Project: http://git-wip-us.apache.org/repos/asf/lucene-solr/repo
Commit: http://git-wip-us.apache.org/repos/asf/lucene-solr/commit/9268b2b3
Tree: http://git-wip-us.apache.org/repos/asf/lucene-solr/tree/9268b2b3
Diff: http://git-wip-us.apache.org/repos/asf/lucene-solr/diff/9268b2b3
Branch: refs/heads/jira/solr-11285-sim
Commit: 9268b2b30fec20b8186ee7b3c077be931bc82d18
Parents: cd10d0b
Author: Christine Poerschke <cp...@apache.org>
Authored: Tue Dec 5 12:19:14 2017 +0000
Committer: Christine Poerschke <cp...@apache.org>
Committed: Tue Dec 5 12:19:14 2017 +0000
----------------------------------------------------------------------
solr/CHANGES.txt | 3 +++
solr/bin/solr | 2 +-
solr/bin/solr.cmd | 4 ++--
3 files changed, 6 insertions(+), 3 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/lucene-solr/blob/9268b2b3/solr/CHANGES.txt
----------------------------------------------------------------------
diff --git a/solr/CHANGES.txt b/solr/CHANGES.txt
index aaefff6..456363f 100644
--- a/solr/CHANGES.txt
+++ b/solr/CHANGES.txt
@@ -165,6 +165,9 @@ Bug Fixes
* SOLR-11687: SolrCore.getNewIndexDir falsely returns {dataDir}/index on any IOException reading index.properties
(Nikolay Martynov, Erick Erickson)
+* SOLR-9137: bin/solr script ignored custom STOP_PORT on shutdown.
+ (Joachim Kohlhammer, Steve Rowe, Christine Poerschke)
+
Optimizations
----------------------
* SOLR-11285: Refactor autoscaling framework to avoid direct references to Zookeeper and Solr
http://git-wip-us.apache.org/repos/asf/lucene-solr/blob/9268b2b3/solr/bin/solr
----------------------------------------------------------------------
diff --git a/solr/bin/solr b/solr/bin/solr
index dd8d6ef..2fb483c 100755
--- a/solr/bin/solr
+++ b/solr/bin/solr
@@ -729,7 +729,7 @@ function stop_solr() {
DIR="$1"
SOLR_PORT="$2"
- STOP_PORT=`expr $SOLR_PORT - 1000`
+ STOP_PORT="${STOP_PORT:-$(expr $SOLR_PORT - 1000)}"
STOP_KEY="$3"
SOLR_PID="$4"
http://git-wip-us.apache.org/repos/asf/lucene-solr/blob/9268b2b3/solr/bin/solr.cmd
----------------------------------------------------------------------
diff --git a/solr/bin/solr.cmd b/solr/bin/solr.cmd
index 57e2e62..035a9db 100644
--- a/solr/bin/solr.cmd
+++ b/solr/bin/solr.cmd
@@ -964,7 +964,7 @@ IF "%SCRIPT_CMD%"=="stop" (
IF "%%j"=="%SOLR_JETTY_HOST%:!SOME_SOLR_PORT!" (
set found_it=1
@echo Stopping Solr process %%k running on port !SOME_SOLR_PORT!
- set /A STOP_PORT=!SOME_SOLR_PORT! - 1000
+ IF "%STOP_PORT%"=="" set /A STOP_PORT=!SOME_SOLR_PORT! - 1000
"%JAVA%" %SOLR_SSL_OPTS% -Djetty.home="%SOLR_SERVER_DIR%" -jar "%SOLR_SERVER_DIR%\start.jar" STOP.PORT=!STOP_PORT! STOP.KEY=%STOP_KEY% --stop
del "%SOLR_TIP%"\bin\solr-!SOME_SOLR_PORT!.port
timeout /T 5
@@ -994,7 +994,7 @@ IF "%SCRIPT_CMD%"=="stop" (
IF "%%M"=="%SOLR_JETTY_HOST%:%SOLR_PORT%" (
set found_it=1
@echo Stopping Solr process %%N running on port %SOLR_PORT%
- set /A STOP_PORT=%SOLR_PORT% - 1000
+ IF "%STOP_PORT%"=="" set /A STOP_PORT=%SOLR_PORT% - 1000
"%JAVA%" %SOLR_SSL_OPTS% -Djetty.home="%SOLR_SERVER_DIR%" -jar "%SOLR_SERVER_DIR%\start.jar" "%SOLR_JETTY_CONFIG%" STOP.PORT=!STOP_PORT! STOP.KEY=%STOP_KEY% --stop
del "%SOLR_TIP%"\bin\solr-%SOLR_PORT%.port
timeout /T 5