Skip to content

Commit 8a3e4c8

Browse files
SOLR-17790: Allow -j option to start with a dash (#3392)
1 parent e3e8548 commit 8a3e4c8

3 files changed

Lines changed: 11 additions & 1 deletion

File tree

solr/CHANGES.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -311,6 +311,8 @@ Bug Fixes
311311

312312
* SOLR-17769: Use S3 RetryStrategy instead of RetryPolicy. This fixes the error caused by using the "Adaptive" retry mode. (Houston Putman)
313313

314+
* SOLR-17790: Allow the -j or --jettyconfig option to start with a dash (-). (Houston Putman)
315+
314316
Dependency Upgrades
315317
---------------------
316318
* SOLR-17471: Upgrade Lucene to 9.12.1. (Pierre Salagnac, Christine Poerschke)

solr/bin/solr

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -792,7 +792,7 @@ if [ $# -gt 0 ]; then
792792
shift 2
793793
;;
794794
-j|--jettyconfig)
795-
if [[ -z "$2" || "${2:0:1}" == "-" ]]; then
795+
if [[ -z "$2" ]]; then
796796
print_usage "$SCRIPT_CMD" "Jetty config is required when using the $1 option!"
797797
exit 1
798798
fi

solr/packaging/test/test_start_solr.bats

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,3 +80,11 @@ teardown() {
8080
run cat ${SOLR_LOGS_DIR}/solr-${SOLR_PORT}-console.log
8181
refute_output --partial 'Exception'
8282
}
83+
84+
@test "start with custom jetty options" {
85+
export ENABLE_REMOTE_JMX_OPTS=true
86+
export RMI_PORT=65535 # need to make sure we don't exceed port range so hard code it
87+
88+
solr start -j "--module=server"
89+
solr assert --started http://localhost:${SOLR_PORT} --timeout 5000
90+
}

0 commit comments

Comments
 (0)