Apache Lucene open-source search software
SOLR-11703: typo in bin/solr "impariment"; change to "disruption"
Cassandra Targett4dac5aad1a6f
diff --git a/solr/bin/solr b/solr/bin/solrindex ef83ceed949..0ce19cbd4e5 100755--- a/solr/bin/solr+++ b/solr/bin/solr@@ -19,7 +19,7 @@## Use solr -help to see available command-line options. In addition# to passing command-line options, this script looks for an include-# file named solr.in.sh to set environment variables. Specifically,+# file named solr.in.sh to set environment variables. Specifically,# the following locations are searched in this order:## ./@@ -34,15 +34,15 @@## $ SOLR_INCLUDE=/path/to/solr.in.sh solr start#-# Note: This is particularly handy for running multiple instances on a+# Note: This is particularly handy for running multiple instances on a# single installation, or for quick tests.#-# Finally, developers and enthusiasts who frequently run from an SVN+# Finally, developers and enthusiasts who frequently run from an SVN# checkout, and do not want to locally modify bin/solr.in.sh, can put# a customized include file at ~/.solr.in.sh.## If you would rather configure startup entirely from the environment, you-# can disable the include by exporting an empty SOLR_INCLUDE, or by+# can disable the include by exporting an empty SOLR_INCLUDE, or by# ensuring that no include files exist in the aforementioned search list.SOLR_SCRIPT="$0"@@ -287,11 +287,11 @@ fifunction print_usage() {CMD="$1"ERROR_MSG="$2"-+if [ "$ERROR_MSG" != "" ]; thenecho -e "\nERROR: $ERROR_MSG\n"fi-+if [ -z "$CMD" ]; thenecho ""echo "Usage: solr COMMAND OPTIONS"@@ -648,7 +648,7 @@ function solr_pid_by_port() {echo "$solrPID"}-# extract the value of the -Djetty.port parameter from a running Solr process+# extract the value of the -Djetty.port parameter from a running Solr processfunction jetty_port() {SOLR_PID="$1"SOLR_PROC=`ps auxww | grep -w $SOLR_PID | grep start\.jar | grep jetty\.port`@@ -660,11 +660,11 @@ function jetty_port() {local jetty_port="${pair[1]}"breakfi- done+ doneecho "$jetty_port"} # end jetty_port func-# run a Solr command-line tool using the SolrCLI class;+# run a Solr command-line tool using the SolrCLI class;# useful for doing cross-platform work from the command-line using Javafunction run_tool() {@@ -723,7 +723,7 @@ function get_info() {return $CODE} # end get_info-# tries to gracefully stop Solr using the Jetty+# tries to gracefully stop Solr using the Jetty# stop command and if that fails, then uses kill -9function stop_solr() {@@ -793,7 +793,7 @@ if [ $# -eq 1 ]; thenfiif [ $# -gt 0 ]; then- # if first arg starts with a dash (and it's not -help or -info),+ # if first arg starts with a dash (and it's not -help or -info),# then assume they are starting Solr, such as: solr -fif [[ $1 == -* ]]; thenSCRIPT_CMD="start"@@ -804,7 +804,7 @@ if [ $# -gt 0 ]; thenelse# no args - just show usage and exitprint_usage ""- exit+ exitfiif [ "$SCRIPT_CMD" == "status" ]; then@@ -826,7 +826,7 @@ if [ "$SCRIPT_CMD" == "healthcheck" ]; thenVERBOSE=""if [ $# -gt 0 ]; then- while true; do+ while true; docase "$1" in-c|-collection)if [[ -z "$2" || "${2:0:1}" == "-" ]]; then@@ -836,7 +836,7 @@ if [ "$SCRIPT_CMD" == "healthcheck" ]; thenHEALTHCHECK_COLLECTION="$2"shift 2;;- -z|-zkhost)+ -z|-zkhost)if [[ -z "$2" || "${2:0:1}" == "-" ]]; thenprint_usage "$SCRIPT_CMD" "ZooKeeper connection string is required when using the $1 option!"exit 1@@ -845,7 +845,7 @@ if [ "$SCRIPT_CMD" == "healthcheck" ]; thenshift 2;;-help|-usage)- print_usage "$SCRIPT_CMD"+ print_usage "$SCRIPT_CMD"exit 0;;-V|--verbose)@@ -857,29 +857,29 @@ if [ "$SCRIPT_CMD" == "healthcheck" ]; thenbreak;;*)- if [ "$1" != "" ]; then+ if [ "$1" != "" ]; thenprint_usage "$SCRIPT_CMD" "Unrecognized or misplaced argument: $1!"exit 1elsebreak # out-of-args, stop looping- fi+ fi;;esacdonefi-+if [ -z "$ZK_HOST" ]; thenZK_HOST=localhost:9983fi-+if [ -z "$HEALTHCHECK_COLLECTION" ]; thenecho "collection parameter is required!"print_usage "healthcheck"- exit 1+ exit 1fi-+run_tool healthcheck -zkHost "$ZK_HOST" -collection "$HEALTHCHECK_COLLECTION" $VERBOSE-+exit $?fi@@ -973,7 +973,7 @@ if [[ "$SCRIPT_CMD" == "create" || "$SCRIPT_CMD" == "create_core" || "$SCRIPT_CMif [ -z "$CREATE_CONFDIR" ]; thenCREATE_CONFDIR='_default'fi-+# validate the confdir arg (if provided)if [[ ! -d "$SOLR_TIP/server/solr/configsets/$CREATE_CONFDIR" && ! -d "$CREATE_CONFDIR" ]]; thenecho -e "\nSpecified configuration directory $CREATE_CONFDIR not found!\n"@@ -1431,13 +1431,13 @@ if [ -z "$SOLR_ULIMIT_CHECKS" ] || [ "$SOLR_ULIMIT_CHECKS" != "false" ]; thenmaxProcs=$(ulimit -u)if [ $openFiles -lt "$SOLR_RECOMMENDED_OPEN_FILES" ]; thenecho "*** [WARN] *** Your open file limit is currently $openFiles. "- echo " It should be set to $SOLR_RECOMMENDED_OPEN_FILES to avoid operational impariment. "+ echo " It should be set to $SOLR_RECOMMENDED_OPEN_FILES to avoid operational disruption. "echo " If you no longer wish to see this warning, set SOLR_ULIMIT_CHECKS to false in your profile or solr.in.sh"fiif [ $maxProcs -lt "$SOLR_RECOMMENDED_MAX_PROCESSES" ]; thenecho "*** [WARN] *** Your Max Processes Limit is currently $maxProcs. "- echo " It should be set to $SOLR_RECOMMENDED_MAX_PROCESSES to avoid operational impariment. "+ echo " It should be set to $SOLR_RECOMMENDED_MAX_PROCESSES to avoid operational disruption. "echo " If you no longer wish to see this warning, set SOLR_ULIMIT_CHECKS to false in your profile or solr.in.sh"fielse@@ -1456,7 +1456,7 @@ SOLR_OPTS=($SOLR_OPTS)PASS_TO_RUN_EXAMPLE=if [ $# -gt 0 ]; then- while true; do+ while true; docase "$1" in-c|-cloud)SOLR_MODE="solrcloud"@@ -1854,9 +1854,9 @@ if [ "$SOLR_MODE" == 'solrcloud' ]; thenif [ -z "$ZK_CLIENT_TIMEOUT" ]; thenZK_CLIENT_TIMEOUT="15000"fi-+CLOUD_MODE_OPTS=("-DzkClientTimeout=$ZK_CLIENT_TIMEOUT")-+if [ "$ZK_HOST" != "" ]; thenCLOUD_MODE_OPTS+=("-DzkHost=$ZK_HOST")else@@ -1871,7 +1871,7 @@ if [ "$SOLR_MODE" == 'solrcloud' ]; thenif [ -e "$SOLR_HOME/collection1/core.properties" ]; thenCLOUD_MODE_OPTS+=('-Dbootstrap_confdir=./solr/collection1/conf' '-Dcollection.configName=myconf' '-DnumShards=1')fi-+elseif [ ! -e "$SOLR_HOME/solr.xml" ]; thenecho -e "\nSolr home directory $SOLR_HOME must contain a solr.xml file!\n"@@ -1928,7 +1928,7 @@ function launch_solr() {run_in_foreground="$1"stop_port="$STOP_PORT"-+SOLR_ADDL_ARGS="$2"SOLR_JETTY_ADDL_CONFIG="$3"@@ -2009,10 +2009,10 @@ function launch_solr() {fiecho -e "\n"fi-+# need to launch solr from the server dircd "$SOLR_SERVER_DIR"-+if [ ! -e "$SOLR_SERVER_DIR/start.jar" ]; thenecho -e "\nERROR: start.jar file not found in $SOLR_SERVER_DIR!\nPlease check your -d parameter to set the correct Solr server directory.\n"exit 1