This is an automated email from the ASF dual-hosted git repository.
malliaridis pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/solr.git
The following commit(s) were added to refs/heads/main by this push:
new a4229e76771 SOLR-17595: Fix Solr examples for Windows (#2909)
a4229e76771 is described below
commit a4229e76771da0125b38204db01ea0934e09c4f4
Author: Christos Malliaridis <[email protected]>
AuthorDate: Tue Dec 17 17:03:22 2024 +0200
SOLR-17595: Fix Solr examples for Windows (#2909)
* Fix argument parsing for -D options with multiple values on Windows
* Fix invalid usage of wildcards in RunExampleTool / PostTool
---
solr/CHANGES.txt | 3 +++
solr/bin/solr.cmd | 1 -
solr/core/src/java/org/apache/solr/cli/RunExampleTool.java | 4 +++-
3 files changed, 6 insertions(+), 2 deletions(-)
diff --git a/solr/CHANGES.txt b/solr/CHANGES.txt
index a5f6c24d1d1..752c2670887 100644
--- a/solr/CHANGES.txt
+++ b/solr/CHANGES.txt
@@ -273,6 +273,9 @@ Bug Fixes
* SOLR-17574: Fix AllowListUrlChecker when liveNodes changes. Remove
ClusterState.getHostAllowList (Bruno Roustant, David Smiley)
+* SOLR-17595: Fix two issues in Solr CLI that prevent Solr from starting with
the techproducts example and from
+ correctly parsing arguments on Windows that start with -D and have multiple
values separated by "," or spaces. (Christos Malliaridis)
+
Dependency Upgrades
---------------------
(No changes)
diff --git a/solr/bin/solr.cmd b/solr/bin/solr.cmd
index b951036a404..b1a3647f6a6 100755
--- a/solr/bin/solr.cmd
+++ b/solr/bin/solr.cmd
@@ -665,7 +665,6 @@ goto repeat_passthru
:end_passthru
set "PASSTHRU=%PASSTHRU_KEY%=%PASSTHRU_VALUES%"
-echo "Passing through %PASSTHRU%"
IF NOT "%SOLR_OPTS%"=="" (
set "SOLR_OPTS=%SOLR_OPTS% %PASSTHRU%"
diff --git a/solr/core/src/java/org/apache/solr/cli/RunExampleTool.java
b/solr/core/src/java/org/apache/solr/cli/RunExampleTool.java
index 6d7b349911c..a3e1cc39f71 100644
--- a/solr/core/src/java/org/apache/solr/cli/RunExampleTool.java
+++ b/solr/core/src/java/org/apache/solr/cli/RunExampleTool.java
@@ -352,7 +352,9 @@ public class RunExampleTool extends ToolBase {
collectionName,
"--type",
"application/xml",
- exampledocsDir.toAbsolutePath() + "/*.xml"
+ "--filetypes",
+ "xml",
+ exampledocsDir.toAbsolutePath().toString()
};
PostTool postTool = new PostTool();
CommandLine postToolCli = SolrCLI.parseCmdLine(postTool, args);