epugh commented on code in PR #1954:
URL: https://github.com/apache/solr/pull/1954#discussion_r1342625290


##########
solr/core/src/java/org/apache/solr/cli/ApiTool.java:
##########
@@ -57,27 +57,28 @@ public List<Option> getOptions() {
             .hasArg()
             .required(true)
             .desc("Send a GET request to a Solr API endpoint.")
-            .build());
+            .build(),
+        SolrCLI.OPTION_CREDENTIALS);
   }
 
   @Override
   public void runImpl(CommandLine cli) throws Exception {
     String response = null;
     String getUrl = cli.getOptionValue("get");
     if (getUrl != null) {
-      response = callGet(getUrl);
+      response = callGet(getUrl, cli.getOptionValue("credentials"));

Review Comment:
   i like that...   It is probably something we should do everywhere.   I 
always struggle with "forbiddenapis" stuff, but you could make a case that 
"cli.getOptionValue(String)" shouldn't be permitted...



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscr...@solr.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscr...@solr.apache.org
For additional commands, e-mail: issues-h...@solr.apache.org

Reply via email to