This is an automated email from the ASF dual-hosted git repository.

epugh pushed a commit to branch branch_9x
in repository https://gitbox.apache.org/repos/asf/solr.git


The following commit(s) were added to refs/heads/branch_9x by this push:
     new f6123135ab4 SOLR-17068: Resolve mish mash of bin/post and bin/solr 
post references in favour of bin/solr post. (#2227)
f6123135ab4 is described below

commit f6123135ab4198f171e2ee0a418112b6f239d3eb
Author: Eric Pugh <[email protected]>
AuthorDate: Fri Feb 2 08:57:18 2024 -0500

    SOLR-17068: Resolve mish mash of bin/post and bin/solr post references in 
favour of bin/solr post. (#2227)
    
    * update various examples to use bin/solr post instead of bin/post.
    
    * Restore the -c parameter to the post tool, and ensure it picks up default 
urls settings if specified.
    
    * Remove special text about how to use tool on Windows as no longer needed
    
    * move all our docker testing and actual docker scripts to using bin/solr 
post command instead of bin/post
---
 solr/CHANGES.txt                                   |  4 ++
 .../src/java/org/apache/solr/cli/PostTool.java     | 22 ++++++-
 .../core/src/java/org/apache/solr/cli/SolrCLI.java | 28 +++++++-
 .../src/test/org/apache/solr/cli/PostToolTest.java | 74 +++++++++++++++++++---
 .../apache/solr/cloud/SolrCloudExampleTest.java    |  9 +--
 solr/docker/scripts/solr-demo                      | 10 +--
 solr/docker/tests/cases/create_core/test.sh        |  2 +-
 solr/docker/tests/cases/create_core_exec/test.sh   |  2 +-
 .../cases/create_core_randomuser_rootgroup/test.sh |  2 +-
 .../empty-varsolr-dir-ramdomuser-rootgroup/test.sh |  2 +-
 .../tests/cases/empty-varsolr-dir-solr/test.sh     |  2 +-
 .../tests/cases/empty-varsolr-dir-user/test.sh     |  2 +-
 .../empty-varsolr-vol-ramdomuser-rootgroup/test.sh |  2 +-
 .../cases/empty-varsolr-vol-solr-nocopy/test.sh    |  2 +-
 .../tests/cases/empty-varsolr-vol-solr/test.sh     |  2 +-
 .../tests/cases/empty-varsolr-vol-user/test.sh     |  2 +-
 solr/docker/tests/cases/gosu/test.sh               |  2 +-
 solr/docker/tests/cases/precreate_core/test.sh     |  2 +-
 .../precreate_core_randomuser_rootgroup/test.sh    |  2 +-
 solr/docker/tests/cases/test_log4j/test.sh         |  2 +-
 solr/docker/tests/cases/user_volume/test.sh        |  2 +-
 solr/example/README.md                             |  4 +-
 solr/example/exampledocs/utf8-example.xml          |  3 +-
 solr/packaging/test/test_post.bats                 | 13 +++-
 .../src/test-files/exampledocs/utf8-example.xml    |  3 +-
 .../deployment-guide/pages/docker-networking.adoc  |  2 +-
 .../deployment-guide/pages/installing-solr.adoc    |  4 +-
 .../getting-started/pages/tutorial-diy.adoc        | 14 ++--
 .../getting-started/pages/tutorial-films.adoc      | 10 ++-
 .../pages/tutorial-techproducts.adoc               |  7 +-
 .../indexing-guide/pages/indexing-with-tika.adoc   | 14 ++--
 .../modules/indexing-guide/pages/post-tool.adoc    | 14 ++--
 .../modules/query-guide/pages/spatial-search.adoc  |  4 +-
 .../modules/query-guide/pages/tagger-handler.adoc  |  4 +-
 34 files changed, 189 insertions(+), 84 deletions(-)

diff --git a/solr/CHANGES.txt b/solr/CHANGES.txt
index 92f981f721a..5d807dc036f 100644
--- a/solr/CHANGES.txt
+++ b/solr/CHANGES.txt
@@ -102,6 +102,10 @@ Improvements
 * SOLR-16397: The v2 endpoint to request the status of asynchronous CoreAdmin 
commands has been updated to be more REST-ful.
   Now available at `GET /api/node/commands/someRequestId` (Sanjay Dutt via 
Jason Gerlowski)
 
+* SOLR-17068: bin/solr post CLI use of options is now aligned closely with 
bin/post CLI tool, and is consistently
+  referenced throughout the Ref Guide and source code, and is used through out 
our tests.  The bin/post tool 
+  remains and has been tested to work. (Eric Pugh)
+
 Optimizations
 ---------------------
 * SOLR-17084: LBSolrClient (used by CloudSolrClient) now returns the count of 
core tracked as not live AKA zombies
diff --git a/solr/core/src/java/org/apache/solr/cli/PostTool.java 
b/solr/core/src/java/org/apache/solr/cli/PostTool.java
index 5e6b5efeef0..51dd10f202e 100644
--- a/solr/core/src/java/org/apache/solr/cli/PostTool.java
+++ b/solr/core/src/java/org/apache/solr/cli/PostTool.java
@@ -44,9 +44,16 @@ public class PostTool extends ToolBase {
         Option.builder("url")
             .argName("url")
             .hasArg()
-            .required(true)
+            .required(false)
             .desc("<base Solr update URL>")
             .build(),
+        Option.builder("c")
+            .longOpt("name")
+            .argName("NAME")
+            .hasArg()
+            .required(false)
+            .desc("Name of the collection.")
+            .build(),
         Option.builder("commit").required(false).desc("Issue a commit at end 
of post").build(),
         Option.builder("optimize").required(false).desc("Issue an optimize at 
end of post").build(),
         Option.builder("mode")
@@ -101,8 +108,17 @@ public class PostTool extends ToolBase {
   public void runImpl(CommandLine cli) throws Exception {
     SolrCLI.raiseLogLevelUnlessVerbose(cli);
 
-    String url = cli.getOptionValue("url");
-    URL solrUrl = new URL(url);
+    URL solrUrl = null;
+    if (cli.hasOption("url")) {
+      String url = cli.getOptionValue("url");
+      solrUrl = new URL(url);
+    } else if (cli.hasOption("c")) {
+      String url = SolrCLI.getDefaultSolrUrl() + "/solr/" + 
cli.getOptionValue("c") + "/update";
+      solrUrl = new URL(url);
+    } else {
+      throw new IllegalArgumentException(
+          "Must specify either -url or -c parameter to post documents.");
+    }
 
     String mode = SimplePostTool.DEFAULT_DATA_MODE;
     if (cli.hasOption("mode")) {
diff --git a/solr/core/src/java/org/apache/solr/cli/SolrCLI.java 
b/solr/core/src/java/org/apache/solr/cli/SolrCLI.java
index 18b92ca8fa0..23b60ff6725 100755
--- a/solr/core/src/java/org/apache/solr/cli/SolrCLI.java
+++ b/solr/core/src/java/org/apache/solr/cli/SolrCLI.java
@@ -520,7 +520,33 @@ public class SolrCLI implements CLIO {
           OPTION_VERBOSE);
 
   /**
-   * Get the base URL of a live Solr instance from either the solrUrl 
command-line option from
+   * Strips off the end of solrUrl any /solr when a legacy solrUrl like 
http://localhost:8983/solr
+   * is used, and warns those users. In the future we'll have urls ending with 
/api as well.
+   *
+   * @param solrUrl The user supplied url to Solr.
+   * @return the solrUrl in the format that Solr expects to see internally.
+   */
+  public static String normalizeSolrUrl(String solrUrl) {
+    if (solrUrl != null) {
+      if (solrUrl.contains("/solr")) { //
+        String newSolrUrl = solrUrl.substring(0, solrUrl.indexOf("/solr"));
+        CLIO.out(
+            "WARNING: URLs provided to this tool needn't include Solr's 
context-root (e.g. \"/solr\"). Such URLs are deprecated and support for them 
will be removed in a future release. Correcting from ["
+                + solrUrl
+                + "] to ["
+                + newSolrUrl
+                + "].");
+        solrUrl = newSolrUrl;
+      }
+      if (solrUrl.endsWith("/")) {
+        solrUrl = solrUrl.substring(0, solrUrl.length() - 1);
+      }
+    }
+    return solrUrl;
+  }
+
+  /**
+   * Get the base URL of a live Solr instance from either the solrUrl 
command-line option or from
    * ZooKeeper.
    */
   public static String resolveSolrUrl(CommandLine cli) throws Exception {
diff --git a/solr/core/src/test/org/apache/solr/cli/PostToolTest.java 
b/solr/core/src/test/org/apache/solr/cli/PostToolTest.java
index 681d788138c..7ada453aa65 100644
--- a/solr/core/src/test/org/apache/solr/cli/PostToolTest.java
+++ b/solr/core/src/test/org/apache/solr/cli/PostToolTest.java
@@ -23,26 +23,84 @@ import static org.apache.solr.cli.SolrCLI.parseCmdLine;
 import org.apache.commons.cli.CommandLine;
 import org.apache.solr.client.solrj.request.CollectionAdminRequest;
 import org.apache.solr.cloud.SolrCloudTestCase;
+import org.apache.solr.common.util.EnvUtils;
+import org.apache.solr.common.util.Utils;
+import org.apache.solr.security.BasicAuthPlugin;
+import org.apache.solr.security.RuleBasedAuthorizationPlugin;
 import org.junit.BeforeClass;
 import org.junit.Test;
 
 public class PostToolTest extends SolrCloudTestCase {
 
   @BeforeClass
-  public static void setupCluster() throws Exception {
-    configureCluster(1)
-        .addConfig(
-            "config", 
TEST_PATH().resolve("configsets").resolve("cloud-minimal").resolve("conf"))
+  public static void setupClusterWithSecurityEnabled() throws Exception {
+    final String SECURITY_JSON =
+        Utils.toJSONString(
+            Map.of(
+                "authorization",
+                Map.of(
+                    "class",
+                    RuleBasedAuthorizationPlugin.class.getName(),
+                    "user-role",
+                    singletonMap(USER, "admin"),
+                    "permissions",
+                    singletonList(Map.of("name", "all", "role", "admin"))),
+                "authentication",
+                Map.of(
+                    "class",
+                    BasicAuthPlugin.class.getName(),
+                    "blockUnknown",
+                    true,
+                    "credentials",
+                    singletonMap(USER, getSaltedHashedValue(PASS)))));
+
+    configureCluster(2)
+        .addConfig("conf1", configset("cloud-minimal"))
+        .withSecurityJson(SECURITY_JSON)
         .configure();
   }
 
   @Test
   public void testBasicRun() throws Exception {
-    final String collection = "aliasedCollection";
-    CollectionAdminRequest.createCollection(collection, "config", 1, 1)
-        .process(cluster.getSolrClient());
+    final String collection = "testBasicRun";
+
+    withBasicAuth(CollectionAdminRequest.createCollection(collection, "conf1", 
1, 1, 0, 0))
+        .processAndWait(cluster.getSolrClient(), 10);
+
+    File jsonDoc = File.createTempFile("temp", ".json");
+
+    FileWriter fw = new FileWriter(jsonDoc, StandardCharsets.UTF_8);
+    Utils.writeJson(Utils.toJSONString(Map.of("id", "1", "title", "mytitle")), 
fw, true);
+
+    String[] args = {
+      "post",
+      "-url",
+      cluster.getJettySolrRunner(0).getBaseUrl() + "/" + collection + 
"/update",
+      "-credentials",
+      USER + ":" + PASS,
+      jsonDoc.getAbsolutePath()
+    };
+    assertEquals(0, runTool(args));
+  }
+
+  @Test
+  public void testRunWithCollectionParam() throws Exception {
+    final String collection = "testRunWithCollectionParam";
+
+    // Provide the port as an environment variable for the PostTool to look up.
+    EnvUtils.setEnv("SOLR_PORT", cluster.getJettySolrRunner(0).getLocalPort() 
+ "");
+
+    withBasicAuth(CollectionAdminRequest.createCollection(collection, "conf1", 
1, 1, 0, 0))
+        .processAndWait(cluster.getSolrClient(), 10);
+
+    File jsonDoc = File.createTempFile("temp", "json");
+
+    FileWriter fw = new FileWriter(jsonDoc, StandardCharsets.UTF_8);
+    Utils.writeJson(Utils.toJSONString(Map.of("id", "1", "title", "mytitle")), 
fw, true);
 
-    String[] args = {"post", "-url", 
"http://localhost:8983/solr/aliasedCollection";, "blah.json"};
+    String[] args = {
+      "post", "-c", collection, "-credentials", USER + ":" + PASS, 
jsonDoc.getAbsolutePath()
+    };
     assertEquals(0, runTool(args));
   }
 
diff --git a/solr/core/src/test/org/apache/solr/cloud/SolrCloudExampleTest.java 
b/solr/core/src/test/org/apache/solr/cloud/SolrCloudExampleTest.java
index 97fafd9a420..b6c63148a4e 100644
--- a/solr/core/src/test/org/apache/solr/cloud/SolrCloudExampleTest.java
+++ b/solr/core/src/test/org/apache/solr/cloud/SolrCloudExampleTest.java
@@ -44,9 +44,10 @@ import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
 /**
- * Emulates bin/solr -e cloud -noprompt; bin/post -c gettingstarted 
example/exampledocs/*.xml; this
- * test is useful for catching regressions in indexing the example docs in 
collections that use data
- * driven functionality and managed schema features of the default configset 
(configsets/_default).
+ * Emulates bin/solr start -e cloud -noprompt; bin/solr post -c gettingstarted
+ * example/exampledocs/*.xml; this test is useful for catching regressions in 
indexing the example
+ * docs in collections that use data driven functionality and managed schema 
features of the default
+ * configset (configsets/_default).
  */
 public class SolrCloudExampleTest extends AbstractFullDistribZkTestBase {
 
@@ -114,7 +115,7 @@ public class SolrCloudExampleTest extends 
AbstractFullDistribZkTestBase {
         invalidToolExitStatus,
         tool.runTool(cli));
 
-    // now index docs like bin/post would, but we can't use SimplePostTool 
because it uses
+    // now index docs like bin/solr post would, but we can't use 
SimplePostTool because it uses
     // System.exit when it encounters an error, which JUnit doesn't like ...
     log.info("Created collection, now posting example docs!");
     Path exampleDocsDir = Path.of(ExternalPaths.SOURCE_HOME, "example", 
"exampledocs");
diff --git a/solr/docker/scripts/solr-demo b/solr/docker/scripts/solr-demo
index 8afdabe44f4..15fb87b45f3 100755
--- a/solr/docker/scripts/solr-demo
+++ b/solr/docker/scripts/solr-demo
@@ -37,13 +37,9 @@ else
   /opt/solr/bin/solr create -c "$CORE"
   echo "Created $CORE"
   echo "Loading example data"
-  post_args=()
-  if [[ -n "${SOLR_PORT:-}" ]]; then
-    post_args+=(-p "$SOLR_PORT")
-  fi
-  /opt/solr/bin/post "${post_args[@]}" -c $CORE -commit no 
example/exampledocs/*.xml
-  /opt/solr/bin/post "${post_args[@]}" -c $CORE -commit no 
example/exampledocs/books.json
-  /opt/solr/bin/post "${post_args[@]}" -c $CORE -commit yes 
example/exampledocs/books.csv
+  /opt/solr/bin/solr post -c $CORE -commit no example/exampledocs/*.xml
+  /opt/solr/bin/solr post -c $CORE -commit no example/exampledocs/books.json
+  /opt/solr/bin/solr post -c $CORE -commit yes example/exampledocs/books.csv
   echo "Loaded example data"
   stop-local-solr
 
diff --git a/solr/docker/tests/cases/create_core/test.sh 
b/solr/docker/tests/cases/create_core/test.sh
index 9d23e55fccc..73ff298aad1 100755
--- a/solr/docker/tests/cases/create_core/test.sh
+++ b/solr/docker/tests/cases/create_core/test.sh
@@ -25,7 +25,7 @@ docker run --name "$container_name" -d "$tag" solr-create -c 
gettingstarted
 wait_for_container_and_solr "$container_name"
 
 echo "Loading data"
-docker exec --user=solr "$container_name" bin/post -c gettingstarted 
example/exampledocs/manufacturers.xml
+docker exec --user=solr "$container_name" bin/solr post -c gettingstarted 
-commit example/exampledocs/manufacturers.xml
 sleep 1
 echo "Checking data"
 data=$(docker exec --user=solr "$container_name" wget -q -O - 
'http://localhost:8983/solr/gettingstarted/select?q=id%3Adell')
diff --git a/solr/docker/tests/cases/create_core_exec/test.sh 
b/solr/docker/tests/cases/create_core_exec/test.sh
index 8f50832248a..4cd8e1f34d7 100755
--- a/solr/docker/tests/cases/create_core_exec/test.sh
+++ b/solr/docker/tests/cases/create_core_exec/test.sh
@@ -27,7 +27,7 @@ wait_for_container_and_solr "$container_name"
 echo "Creating core"
 docker exec --user=solr "$container_name" bin/solr create_core -c 
gettingstarted
 echo "Loading data"
-docker exec --user=solr "$container_name" bin/post -c gettingstarted 
example/exampledocs/manufacturers.xml
+docker exec --user=solr "$container_name" bin/solr post -c gettingstarted 
-commit example/exampledocs/manufacturers.xml
 sleep 1
 echo "Checking data"
 data=$(docker exec --user=solr "$container_name" wget -q -O - 
'http://localhost:8983/solr/gettingstarted/select?q=id%3Adell')
diff --git a/solr/docker/tests/cases/create_core_randomuser_rootgroup/test.sh 
b/solr/docker/tests/cases/create_core_randomuser_rootgroup/test.sh
index 281683e666c..a777e061eb6 100755
--- a/solr/docker/tests/cases/create_core_randomuser_rootgroup/test.sh
+++ b/solr/docker/tests/cases/create_core_randomuser_rootgroup/test.sh
@@ -27,7 +27,7 @@ docker run --user 7777:0 --name "$container_name" -d "$tag" 
solr-create -c getti
 wait_for_container_and_solr "$container_name"
 
 echo "Loading data"
-docker exec --user=solr "$container_name" bin/post -c gettingstarted 
example/exampledocs/manufacturers.xml
+docker exec --user=solr "$container_name" bin/solr post -c gettingstarted 
-commit example/exampledocs/manufacturers.xml
 sleep 1
 echo "Checking data"
 data=$(docker exec --user=solr "$container_name" wget -q -O - 
'http://localhost:8983/solr/gettingstarted/select?q=id%3Adell')
diff --git 
a/solr/docker/tests/cases/empty-varsolr-dir-ramdomuser-rootgroup/test.sh 
b/solr/docker/tests/cases/empty-varsolr-dir-ramdomuser-rootgroup/test.sh
index 37f150ddf1b..90dc4c495fc 100755
--- a/solr/docker/tests/cases/empty-varsolr-dir-ramdomuser-rootgroup/test.sh
+++ b/solr/docker/tests/cases/empty-varsolr-dir-ramdomuser-rootgroup/test.sh
@@ -32,7 +32,7 @@ docker run \
 wait_for_container_and_solr "$container_name"
 
 echo "Loading data"
-docker exec --user=solr "$container_name" bin/post -c getting-started 
example/exampledocs/manufacturers.xml
+docker exec --user=solr "$container_name" bin/solr post -c getting-started 
-commit example/exampledocs/manufacturers.xml
 sleep 1
 echo "Checking data"
 data=$(docker exec --user=solr "$container_name" wget -q -O - 
'http://localhost:8983/solr/getting-started/select?q=id%3Adell')
diff --git a/solr/docker/tests/cases/empty-varsolr-dir-solr/test.sh 
b/solr/docker/tests/cases/empty-varsolr-dir-solr/test.sh
index 155b135f3b9..aee5986a93f 100755
--- a/solr/docker/tests/cases/empty-varsolr-dir-solr/test.sh
+++ b/solr/docker/tests/cases/empty-varsolr-dir-solr/test.sh
@@ -31,7 +31,7 @@ docker run \
 wait_for_container_and_solr "$container_name"
 
 echo "Loading data"
-docker exec --user=solr "$container_name" bin/post -c getting-started 
example/exampledocs/manufacturers.xml
+docker exec --user=solr "$container_name" bin/solr post -c getting-started 
-commit example/exampledocs/manufacturers.xml
 sleep 1
 echo "Checking data"
 data=$(docker exec --user=solr "$container_name" wget -q -O - 
'http://localhost:8983/solr/getting-started/select?q=id%3Adell')
diff --git a/solr/docker/tests/cases/empty-varsolr-dir-user/test.sh 
b/solr/docker/tests/cases/empty-varsolr-dir-user/test.sh
index e9d42f75ba9..25d7f99ac66 100755
--- a/solr/docker/tests/cases/empty-varsolr-dir-user/test.sh
+++ b/solr/docker/tests/cases/empty-varsolr-dir-user/test.sh
@@ -32,7 +32,7 @@ docker run \
 wait_for_container_and_solr "$container_name"
 
 echo "Loading data"
-docker exec --user=solr "$container_name" bin/post -c getting-started 
example/exampledocs/manufacturers.xml
+docker exec --user=solr "$container_name" bin/solr post -c getting-started 
-commit example/exampledocs/manufacturers.xml
 sleep 1
 echo "Checking data"
 data=$(docker exec --user=solr "$container_name" wget -q -O - 
'http://localhost:8983/solr/getting-started/select?q=id%3Adell')
diff --git 
a/solr/docker/tests/cases/empty-varsolr-vol-ramdomuser-rootgroup/test.sh 
b/solr/docker/tests/cases/empty-varsolr-vol-ramdomuser-rootgroup/test.sh
index 402a66acbd8..6bd50085542 100755
--- a/solr/docker/tests/cases/empty-varsolr-vol-ramdomuser-rootgroup/test.sh
+++ b/solr/docker/tests/cases/empty-varsolr-vol-ramdomuser-rootgroup/test.sh
@@ -36,7 +36,7 @@ docker run \
 wait_for_container_and_solr "$container_name"
 
 echo "Loading data"
-docker exec --user=solr "$container_name" bin/post -c getting-started 
example/exampledocs/manufacturers.xml
+docker exec --user=solr "$container_name" bin/solr post -c getting-started 
-commit example/exampledocs/manufacturers.xml
 sleep 1
 echo "Checking data"
 data=$(docker exec --user=solr "$container_name" wget -q -O - 
'http://localhost:8983/solr/getting-started/select?q=id%3Adell')
diff --git a/solr/docker/tests/cases/empty-varsolr-vol-solr-nocopy/test.sh 
b/solr/docker/tests/cases/empty-varsolr-vol-solr-nocopy/test.sh
index 11dc15416c0..d6e3e1a9063 100755
--- a/solr/docker/tests/cases/empty-varsolr-vol-solr-nocopy/test.sh
+++ b/solr/docker/tests/cases/empty-varsolr-vol-solr-nocopy/test.sh
@@ -42,7 +42,7 @@ docker run \
 wait_for_container_and_solr "$container_name"
 
 echo "Loading data"
-docker exec --user=solr "$container_name" bin/post -c getting-started 
example/exampledocs/manufacturers.xml
+docker exec --user=solr "$container_name" bin/solr post -c getting-started 
-commit example/exampledocs/manufacturers.xml
 sleep 1
 echo "Checking data"
 data=$(docker exec --user=solr "$container_name" wget -q -O - 
'http://localhost:8983/solr/getting-started/select?q=id%3Adell')
diff --git a/solr/docker/tests/cases/empty-varsolr-vol-solr/test.sh 
b/solr/docker/tests/cases/empty-varsolr-vol-solr/test.sh
index 6a6416d7f00..fe12c869caa 100755
--- a/solr/docker/tests/cases/empty-varsolr-vol-solr/test.sh
+++ b/solr/docker/tests/cases/empty-varsolr-vol-solr/test.sh
@@ -35,7 +35,7 @@ docker run \
 wait_for_container_and_solr "$container_name"
 
 echo "Loading data"
-docker exec --user=solr "$container_name" bin/post -c getting-started 
example/exampledocs/manufacturers.xml
+docker exec --user=solr "$container_name" bin/solr post -c getting-started 
-commit example/exampledocs/manufacturers.xml
 sleep 1
 echo "Checking data"
 data=$(docker exec --user=solr "$container_name" wget -q -O - 
'http://localhost:8983/solr/getting-started/select?q=id%3Adell')
diff --git a/solr/docker/tests/cases/empty-varsolr-vol-user/test.sh 
b/solr/docker/tests/cases/empty-varsolr-vol-user/test.sh
index 26fa5505778..7e3e615dd86 100755
--- a/solr/docker/tests/cases/empty-varsolr-vol-user/test.sh
+++ b/solr/docker/tests/cases/empty-varsolr-vol-user/test.sh
@@ -44,7 +44,7 @@ docker run \
 wait_for_container_and_solr "$container_name"
 
 echo "Loading data"
-docker exec --user=solr "$container_name" bin/post -c getting-started 
example/exampledocs/manufacturers.xml
+docker exec --user=solr "$container_name" bin/solr post -c getting-started 
-commit example/exampledocs/manufacturers.xml
 sleep 1
 echo "Checking data"
 data=$(docker exec --user=solr "$container_name" wget -q -O - 
'http://localhost:8983/solr/getting-started/select?q=id%3Adell')
diff --git a/solr/docker/tests/cases/gosu/test.sh 
b/solr/docker/tests/cases/gosu/test.sh
index 657a0446033..1a3f5aacfa6 100755
--- a/solr/docker/tests/cases/gosu/test.sh
+++ b/solr/docker/tests/cases/gosu/test.sh
@@ -38,7 +38,7 @@ docker run --user 0:0 --name "$container_name" -d -e 
VERBOSE=yes \
 wait_for_container_and_solr "$container_name"
 
 echo "Loading data"
-docker exec --user=solr "$container_name" bin/post -c gettingstarted 
example/exampledocs/manufacturers.xml
+docker exec --user=solr "$container_name" bin/solr post -c gettingstarted 
-commit example/exampledocs/manufacturers.xml
 sleep 1
 echo "Checking data"
 data=$(docker exec --user=solr "$container_name" wget -q -O - 
'http://localhost:8983/solr/gettingstarted/select?q=id%3Adell')
diff --git a/solr/docker/tests/cases/precreate_core/test.sh 
b/solr/docker/tests/cases/precreate_core/test.sh
index ab314186f7d..f9f766bd024 100755
--- a/solr/docker/tests/cases/precreate_core/test.sh
+++ b/solr/docker/tests/cases/precreate_core/test.sh
@@ -25,7 +25,7 @@ docker run --name "$container_name" -d -e VERBOSE=yes "$tag" 
solr-precreate gett
 wait_for_container_and_solr "$container_name"
 
 echo "Loading data"
-docker exec --user=solr "$container_name" bin/post -c gettingstarted 
example/exampledocs/manufacturers.xml
+docker exec --user=solr "$container_name" bin/solr post -c gettingstarted 
-commit example/exampledocs/manufacturers.xml
 sleep 1
 echo "Checking data"
 data=$(docker exec --user=solr "$container_name" wget -q -O - 
'http://localhost:8983/solr/gettingstarted/select?q=id%3Adell')
diff --git 
a/solr/docker/tests/cases/precreate_core_randomuser_rootgroup/test.sh 
b/solr/docker/tests/cases/precreate_core_randomuser_rootgroup/test.sh
index 633929d785c..008aab98376 100755
--- a/solr/docker/tests/cases/precreate_core_randomuser_rootgroup/test.sh
+++ b/solr/docker/tests/cases/precreate_core_randomuser_rootgroup/test.sh
@@ -30,7 +30,7 @@ docker run \
 wait_for_container_and_solr "$container_name"
 
 echo "Loading data"
-docker exec --user=solr "$container_name" bin/post -c gettingstarted 
example/exampledocs/manufacturers.xml
+docker exec --user=solr "$container_name" bin/solr post -c gettingstarted 
-commit example/exampledocs/manufacturers.xml
 sleep 1
 echo "Checking data"
 data=$(docker exec --user=solr "$container_name" wget -q -O - 
'http://localhost:8983/solr/gettingstarted/select?q=id%3Adell')
diff --git a/solr/docker/tests/cases/test_log4j/test.sh 
b/solr/docker/tests/cases/test_log4j/test.sh
index 78f3a5856d9..31a66a8e8b0 100755
--- a/solr/docker/tests/cases/test_log4j/test.sh
+++ b/solr/docker/tests/cases/test_log4j/test.sh
@@ -29,7 +29,7 @@ docker run --name "$container_name" -d -e VERBOSE=yes \
 wait_for_container_and_solr "$container_name"
 
 echo "Loading data"
-docker exec --user=solr "$container_name" bin/post -c gettingstarted 
example/exampledocs/manufacturers.xml
+docker exec --user=solr "$container_name" bin/solr post -c gettingstarted 
-commit example/exampledocs/manufacturers.xml
 sleep 1
 echo "Checking data"
 data=$(docker exec --user=solr "$container_name" wget -q -O - 
'http://localhost:8983/solr/gettingstarted/select?q=id%3Adell')
diff --git a/solr/docker/tests/cases/user_volume/test.sh 
b/solr/docker/tests/cases/user_volume/test.sh
index 92544518f85..3fa2fdeb524 100755
--- a/solr/docker/tests/cases/user_volume/test.sh
+++ b/solr/docker/tests/cases/user_volume/test.sh
@@ -67,7 +67,7 @@ docker run \
 wait_for_container_and_solr "$container_name"
 
 echo "Loading data"
-docker exec --user=solr "$container_name" bin/post -c mycore 
example/exampledocs/manufacturers.xml
+docker exec --user=solr "$container_name" bin/solr post -c mycore -commit 
example/exampledocs/manufacturers.xml
 sleep 1
 echo "Checking data"
 data=$(docker exec --user=solr "$container_name" wget -q -O - 
'http://localhost:8983/solr/mycore/select?q=id%3Adell')
diff --git a/solr/example/README.md b/solr/example/README.md
index f7a9b76135b..a08dec53ba8 100644
--- a/solr/example/README.md
+++ b/solr/example/README.md
@@ -48,10 +48,10 @@ After starting a Solr example, direct your Web browser to:
   http://localhost:8983/solr/
 ```
 
-To add documents to the index, use bin/post, for example:
+To add documents to the index, use bin/solr post, for example:
 
 ```
-     bin/post -c techproducts example/exampledocs/*.xml
+     bin/solr post -c techproducts example/exampledocs/*.xml
 ```
 
 (where "techproducts" is the Solr core name)
diff --git a/solr/example/exampledocs/utf8-example.xml 
b/solr/example/exampledocs/utf8-example.xml
index ee300a68306..e785b38199b 100644
--- a/solr/example/exampledocs/utf8-example.xml
+++ b/solr/example/exampledocs/utf8-example.xml
@@ -17,7 +17,7 @@
 -->
 
 <!-- 
-  After posting this to Solr with bin/post, searching for "êâîôû" from
+  After posting this to Solr with bin/solr post, searching for "êâîôû" from
   the solr/admin/ search page must return this document.
  -->
 
@@ -39,4 +39,3 @@
     <field name="inStock">true</field>
   </doc>
 </add>
-
diff --git a/solr/packaging/test/test_post.bats 
b/solr/packaging/test/test_post.bats
index 1b0d11705a1..e2262eb3bac 100644
--- a/solr/packaging/test/test_post.bats
+++ b/solr/packaging/test/test_post.bats
@@ -39,7 +39,7 @@ teardown() {
 @test "Check help command" {
 
   run solr post
-  assert_output --partial 'Failed to parse command-line arguments due to: 
Missing required option: url'
+  assert_output --partial 'Must specify either -url or -c parameter'
   
   run solr post -h
   assert_output --partial 'usage: post'
@@ -63,6 +63,17 @@ teardown() {
   refute_output --partial 'ERROR'
 }
 
+@test "basic post with c parameter instead of url parameter" {
+  
+  run solr create -c monitors_c_param -d _default
+  assert_output --partial "Created collection 'monitors_c_param'"
+  
+  run solr post -type application/xml -c monitors_c_param 
${SOLR_TIP}/example/exampledocs/monitor.xml
+
+  assert_output --partial '1 files indexed.'
+  refute_output --partial 'ERROR'
+}
+
 @test "basic post WITHOUT a type specified" {
   
   solr create_collection -c monitors_no_type -d _default
diff --git 
a/solr/prometheus-exporter/src/test-files/exampledocs/utf8-example.xml 
b/solr/prometheus-exporter/src/test-files/exampledocs/utf8-example.xml
index ee300a68306..e785b38199b 100644
--- a/solr/prometheus-exporter/src/test-files/exampledocs/utf8-example.xml
+++ b/solr/prometheus-exporter/src/test-files/exampledocs/utf8-example.xml
@@ -17,7 +17,7 @@
 -->
 
 <!-- 
-  After posting this to Solr with bin/post, searching for "êâîôû" from
+  After posting this to Solr with bin/solr post, searching for "êâîôû" from
   the solr/admin/ search page must return this document.
  -->
 
@@ -39,4 +39,3 @@
     <field name="inStock">true</field>
   </doc>
 </add>
-
diff --git 
a/solr/solr-ref-guide/modules/deployment-guide/pages/docker-networking.adoc 
b/solr/solr-ref-guide/modules/deployment-guide/pages/docker-networking.adoc
index 32f6aa14ce2..d8ba979b26b 100644
--- a/solr/solr-ref-guide/modules/deployment-guide/pages/docker-networking.adoc
+++ b/solr/solr-ref-guide/modules/deployment-guide/pages/docker-networking.adoc
@@ -204,7 +204,7 @@ To load data, and see it was split over shards:
 
 [source,bash,subs="attributes"]
 ----
-docker exec -it --user=solr zksolr1 bin/post -c my_collection1 
example/exampledocs/manufacturers.xml
+docker exec -it --user=solr zksolr1 bin/solr post -c my_collection1 
example/exampledocs/manufacturers.xml
 # /usr/lib/jvm/java-8-openjdk-amd64/jre/bin/java -classpath 
/opt/solr/server/lib/ext/*:/opt/solr/server/solr-webapp/webapp/WEB-INF/lib/* 
-Dauto=yes -Dc=my_collection1 -Ddata=files org.apache.solr.cli.SimplePostTool 
example/exampledocs/manufacturers.xml
 # SimplePostTool version {solr-full-version}
 # Posting files to [base] url 
http://localhost:8983/solr/my_collection1/update...
diff --git 
a/solr/solr-ref-guide/modules/deployment-guide/pages/installing-solr.adoc 
b/solr/solr-ref-guide/modules/deployment-guide/pages/installing-solr.adoc
index b9addf2cdb3..4d7ec43f864 100644
--- a/solr/solr-ref-guide/modules/deployment-guide/pages/installing-solr.adoc
+++ b/solr/solr-ref-guide/modules/deployment-guide/pages/installing-solr.adoc
@@ -144,8 +144,8 @@ If you ran through the 
xref:getting-started:solr-tutorial.adoc[], you have alrea
 Here are the examples included with Solr:
 
 exampledocs::
-This is a small set of simple CSV, XML, and JSON files that can be used with 
`bin/post` when first getting started with Solr.
-For more information about using `bin/post` with these files, see 
xref:indexing-guide:post-tool.adoc[].
+This is a small set of simple CSV, XML, and JSON files that can be used with 
`bin/solr post` when first getting started with Solr.
+For more information about using `bin/solr post` with these files, see 
xref:indexing-guide:post-tool.adoc[].
 
 files::
 The `files` directory provides a basic search UI for documents such as Word or 
PDF that you may have stored locally.
diff --git 
a/solr/solr-ref-guide/modules/getting-started/pages/tutorial-diy.adoc 
b/solr/solr-ref-guide/modules/getting-started/pages/tutorial-diy.adoc
index 57d4197b740..8a953676e99 100644
--- a/solr/solr-ref-guide/modules/getting-started/pages/tutorial-diy.adoc
+++ b/solr/solr-ref-guide/modules/getting-started/pages/tutorial-diy.adoc
@@ -49,8 +49,8 @@ You may need to iterate on indexing a few times before you 
get the schema right.
 Solr has lots of ways to index data.
 Choose one of the approaches below and try it out with your system:
 
-Local Files with `bin/post`::
-If you have a local directory of files, the Post Tool (`bin/post`) can index a 
directory of files.
+Local Files with `bin/solr post`::
+If you have a local directory of files, the Post Tool (`bin/solr post`) can 
index a directory of files.
 We saw this in action in our first exercise.
 +
 We used only JSON, XML and CSV in our exercises, but the Post Tool can also 
handle HTML, PDF, Microsoft Office formats (such as MS Word), plain text, and 
more.
@@ -60,7 +60,7 @@ To index it, we would issue a command like this (correcting 
the collection name
 +
 [,console]
 ----
-$ bin/post -c localDocs ~/Documents
+$ bin/solr post -c localDocs ~/Documents
 ----
 +
 You may get errors as it works through your documents.
@@ -87,7 +87,7 @@ You can see that has happened by looking at the values for 
`numDocs` and `maxDoc
 The `maxDoc` value may be larger as the `maxDoc` count includes logically 
deleted documents that have not yet been physically removed from the index.
 You can re-post the sample files over and over again as much as you want and 
`numDocs` will never increase, because the new documents will constantly be 
replacing the old.
 
-Go ahead and edit any of the existing example data files, change some of the 
data, and re-run the PostTool (`bin/post`).
+Go ahead and edit any of the existing example data files, change some of the 
data, and re-run the PostTool (`bin/solr post`).
 You'll see your changes reflected in subsequent searches.
 
 === Deleting Data
@@ -97,20 +97,20 @@ Note, however, that merely removing documents doesn't 
change the underlying fiel
 Essentially, this will allow you to reindex your data after making changes to 
fields for your needs.
 
 You can delete data by POSTing a delete command to the update URL and 
specifying the value of the document's unique key field, or a query that 
matches multiple documents (be careful with that one!).
-We can use `bin/post` to delete documents also if we structure the request 
properly.
+We can use `bin/solr post` to delete documents also if we structure the 
request properly.
 
 Execute the following command to delete a specific document:
 
 [,console]
 ----
-$ bin/post -c localDocs -d "<delete><id>SP2514N</id></delete>"
+$ bin/solr post -c localDocs -d "<delete><id>SP2514N</id></delete>"
 ----
 
 To delete all documents, you can use "delete-by-query" command like:
 
 [,console]
 ----
-$ bin/post -c localDocs -d "<delete><query>*:*</query></delete>"
+$ bin/solr post -c localDocs -d "<delete><query>*:*</query></delete>"
 ----
 
 You can also modify the above to only delete documents that match a specific 
query.
diff --git 
a/solr/solr-ref-guide/modules/getting-started/pages/tutorial-films.adoc 
b/solr/solr-ref-guide/modules/getting-started/pages/tutorial-films.adoc
index 2a3becad0c3..edc7758f0bf 100644
--- a/solr/solr-ref-guide/modules/getting-started/pages/tutorial-films.adoc
+++ b/solr/solr-ref-guide/modules/getting-started/pages/tutorial-films.adoc
@@ -227,7 +227,7 @@ Pick one of the formats and index it into the "films" 
collection (in each exampl
 
 [,console]
 ----
-$ bin/post -c films example/films/films.json
+$ bin/solr post -c films example/films/films.json
 
 ----
 ====
@@ -253,7 +253,7 @@ $ bin/solr post -c films example\films\films.json
 
 [,console]
 ----
-$ bin/post -c films example/films/films.xml
+$ bin/solr post -c films example/films/films.xml
 
 ----
 ====
@@ -279,7 +279,7 @@ $ java -jar -Dc=films -Dauto example\exampledocs\post.jar 
example\films\*.xml
 
 [,console]
 ----
-$ bin/post -c films example/films/films.csv -params 
"f.genre.split=true&f.directed_by.split=true&f.genre.separator=|&f.directed_by.separator=|"
+$ bin/solr post -c films example/films/films.csv -params 
"f.genre.split=true&f.directed_by.split=true&f.genre.separator=|&f.directed_by.separator=|"
 
 ----
 ====
@@ -309,9 +309,7 @@ Each command will produce output similar to the below seen 
while indexing JSON:
 
 [,console]
 ----
-$ bin/post -c films example/films/films.json
-# bin/java -classpath 
/solr-{solr-full-version}/server/solr-webapp/webapp/WEB-INF/lib/solr-core-{solr-full-version}.jar
 -Dauto=yes -Dc=films -Ddata=files org.apache.solr.cli.SimplePostTool 
example/films/films.json
-SimplePostTool version 5.0.0
+$ bin/solr post -c films example/films/films.json
 Posting files to [base] url http://localhost:8983/solr/films/update...
 Entering auto mode. File endings considered are 
xml,json,jsonl,csv,pdf,doc,docx,ppt,pptx,xls,xlsx,odt,odp,ods,ott,otp,ots,rtf,htm,html,txt,log
 POSTing file films.json (application/json) to [base]/json/docs
diff --git 
a/solr/solr-ref-guide/modules/getting-started/pages/tutorial-techproducts.adoc 
b/solr/solr-ref-guide/modules/getting-started/pages/tutorial-techproducts.adoc
index 2994bc905af..b2cb956a2ae 100644
--- 
a/solr/solr-ref-guide/modules/getting-started/pages/tutorial-techproducts.adoc
+++ 
b/solr/solr-ref-guide/modules/getting-started/pages/tutorial-techproducts.adoc
@@ -159,21 +159,18 @@ image::solr-tutorial/tutorial-solrcloud.png[]
 
 Your Solr server is up and running, but it doesn't contain any data yet, so we 
can't do any queries.
 
-Solr includes the `bin/post` tool in order to facilitate indexing various 
types of documents easily.
+Solr includes the `bin/solr post` tool in order to facilitate indexing various 
types of documents easily.
 We'll use this tool for the indexing examples below.
 
 You'll need a command shell to run some of the following examples, rooted in 
the Solr install directory; the shell from where you launched Solr works just 
fine.
 
-NOTE: Currently the `bin/post` tool does not have a comparable Windows script, 
but the `bin/solr post` command is available on Windows.
-See the section xref:indexing-guide:post-tool.adoc[] for more information.
-
 The data we will index is in the `example/exampledocs` directory.
 The documents are in a mix of document formats (JSON, CSV, etc.), and 
fortunately we can index them all at once:
 
 .Linux/Mac
 [,console]
 ----
-$ bin/post -c techproducts example/exampledocs/*
+$ bin/solr post -c techproducts example/exampledocs/*
 ----
 
 .Windows
diff --git 
a/solr/solr-ref-guide/modules/indexing-guide/pages/indexing-with-tika.adoc 
b/solr/solr-ref-guide/modules/indexing-guide/pages/indexing-with-tika.adoc
index 4ba4f52f26f..d32fe2b7b75 100644
--- a/solr/solr-ref-guide/modules/indexing-guide/pages/indexing-with-tika.adoc
+++ b/solr/solr-ref-guide/modules/indexing-guide/pages/indexing-with-tika.adoc
@@ -124,11 +124,11 @@ The `@` symbol instructs curl to upload the attached file.
 * The argument `myfile=@example/exampledocs/solr-word.pdf` uploads the sample 
file.
 Note this includes the path, so if you upload a different file, always be sure 
to include either the relative or absolute path to the file.
 
-You can also use `bin/post` to do the same thing:
+You can also use `bin/solr post` to do the same thing:
 
 [source,bash]
 ----
-bin/post -c gettingstarted example/exampledocs/solr-word.pdf -params 
"literal.id=doc1"
+bin/solr post -c gettingstarted example/exampledocs/solr-word.pdf -params 
"literal.id=doc1"
 ----
 
 Now you can execute a query and find that document with a request like 
`\http://localhost:8983/solr/gettingstarted/select?q=pdf`.
@@ -148,7 +148,7 @@ Here's an example:
 
 [source,bash]
 ----
-bin/post -c gettingstarted example/exampledocs/solr-word.pdf -params 
"literal.id=doc1&uprefix=ignored_&fmap.last_modified=last_modified_dt"
+bin/solr post -c gettingstarted example/exampledocs/solr-word.pdf -params 
"literal.id=doc1&uprefix=ignored_&fmap.last_modified=last_modified_dt"
 ----
 
 [NOTE]
@@ -563,7 +563,7 @@ The command below captures `<div>` tags separately 
(`capture=div`), and then map
 
 [source,bash]
 ----
-bin/post -c gettingstarted example/exampledocs/sample.html -params 
"literal.id=doc2&captureAttr=true&defaultField=_text_&fmap.div=foo_t&capture=div"
+bin/solr post -c gettingstarted example/exampledocs/sample.html -params 
"literal.id=doc2&captureAttr=true&defaultField=_text_&fmap.div=foo_t&capture=div"
 ----
 
 === Using Literals to Define Custom Metadata
@@ -572,7 +572,7 @@ To add in your own metadata, pass in the literal parameter 
along with the file:
 
 [source,bash]
 ----
-bin/post -c gettingstarted -params 
"literal.id=doc4&captureAttr=true&defaultField=text&capture=div&fmap.div=foo_t&literal.blah_s=Bah"
 example/exampledocs/sample.html
+bin/solr post -c gettingstarted -params 
"literal.id=doc4&captureAttr=true&defaultField=text&capture=div&fmap.div=foo_t&literal.blah_s=Bah"
 example/exampledocs/sample.html
 ----
 
 The parameter `literal.blah_s=Bah` will insert a field `blah_s` into every 
document.
@@ -584,7 +584,7 @@ The example below passes in an XPath expression to restrict 
the XHTML returned b
 
 [source,bash]
 ----
-bin/post -c gettingstarted -params 
"literal.id=doc5&captureAttr=true&defaultField=text&capture=div&fmap.div=foo_t&xpath=/xhtml:html/xhtml:body/xhtml:div//node()"
 example/exampledocs/sample.html
+bin/solr post -c gettingstarted -params 
"literal.id=doc5&captureAttr=true&defaultField=text&capture=div&fmap.div=foo_t&xpath=/xhtml:html/xhtml:body/xhtml:div//node()"
 example/exampledocs/sample.html
 ----
 
 === Extracting Data without Indexing
@@ -603,7 +603,7 @@ The output includes XML generated by Tika (and further 
escaped by Solr's XML) us
 
 [source,bash]
 ----
-bin/post -c gettingstarted -params "extractOnly=true&wt=ruby&indent=true" -out 
yes example/exampledocs/sample.html
+bin/solr post -c gettingstarted -params "extractOnly=true&wt=ruby&indent=true" 
-out yes example/exampledocs/sample.html
 ----
 
 === Using Solr Cell with a POST Request
diff --git a/solr/solr-ref-guide/modules/indexing-guide/pages/post-tool.adoc 
b/solr/solr-ref-guide/modules/indexing-guide/pages/post-tool.adoc
index 10ddd5edc17..d06e07c440c 100644
--- a/solr/solr-ref-guide/modules/indexing-guide/pages/post-tool.adoc
+++ b/solr/solr-ref-guide/modules/indexing-guide/pages/post-tool.adoc
@@ -16,14 +16,11 @@
 // specific language governing permissions and limitations
 // under the License.
 
-Solr includes a simple command line tool for POSTing various types of content 
to a Solr server.
-
-The tool is `bin/solr post`.
-The bin/solr post tool is a Unix shell script; for Windows (non-Cygwin) 
usage,use `bin/solr.cmd post`.
+Solr includes a simple command line tool for POSTing various types of content 
to a Solr server that is part of the `bin/solr` CLI.
 
 NOTE: This tool is meant for use by new users exploring Solr's capabilities, 
and is not intended as a robust solution to be used for indexing documents into 
production systems.
 
-NOTE: You may be familiar with SimplePostTool and the bin/post Unix shell 
script.  While this is still available, it is deprecated and will be removed in 
Solr 10.
+NOTE: You may be familiar with SimplePostTool and the `bin/post` Unix shell 
script.  While this is still available, it is deprecated and will be removed in 
Solr 10.
 
 
 To run it, open a window and enter:
@@ -38,7 +35,10 @@ The `-help` (or simply `-h`) option will output information 
on its usage (i.e.,
 
 == Using the bin/solr post Tool
 
-Specifying the full update `url` is *mandatory* when using `bin/solr post`.
+You must either specify `url` that is the full path to the update handler or 
provide a `c` collection/core name when using `bin/solr post`.
+
+This specifies the same target collection: `-url 
http://localhost:8983/gettingstarted/update` or `-c gettingstarted`.
+
 
 The basic usage of `bin/solr post` is:
 
@@ -118,7 +118,7 @@ Index all CSV and JSON files into `gettingstarted` from 
current directory:
 
 [source,bash]
 ----
-bin/solr post -url http://localhost:8983/solr/gettingstarted/update -filetypes 
json,csv .
+bin/solr post -c gettingstarted -filetypes json,csv .
 ----
 
 Index a tab-separated file into `gettingstarted`:
diff --git a/solr/solr-ref-guide/modules/query-guide/pages/spatial-search.adoc 
b/solr/solr-ref-guide/modules/query-guide/pages/spatial-search.adoc
index dadaeef4cb1..4b25e51a9c9 100644
--- a/solr/solr-ref-guide/modules/query-guide/pages/spatial-search.adoc
+++ b/solr/solr-ref-guide/modules/query-guide/pages/spatial-search.adoc
@@ -68,10 +68,10 @@ However, it's much bulkier than the raw coordinates for 
such simple data.
 
 === Indexing GeoJSON and WKT
 
-Using the `bin/post` tool:
+Using the `bin/solr post` tool:
 
 [source,text]
-bin/post -type "application/json" -url 
"http://localhost:8983/solr/mycollection/update?format=geojson"; 
/path/to/geojson.file
+bin/solr post -type "application/json" -url 
"http://localhost:8983/solr/mycollection/update?format=geojson"; 
/path/to/geojson.file
 
 The key parameter to pass in with your request is:
 
diff --git a/solr/solr-ref-guide/modules/query-guide/pages/tagger-handler.adoc 
b/solr/solr-ref-guide/modules/query-guide/pages/tagger-handler.adoc
index 81b0f176779..31ef089f593 100644
--- a/solr/solr-ref-guide/modules/query-guide/pages/tagger-handler.adoc
+++ b/solr/solr-ref-guide/modules/query-guide/pages/tagger-handler.adoc
@@ -274,10 +274,10 @@ should be almost 7MB file expanding to a cities1000.txt 
file around
 22.2MB containing 145k lines, each a city in the world of at least 1000
 population.
 
-Using bin/post:
+Using bin/solr post:
 [source,bash]
 ----
-bin/post -c geonames -type text/csv \
+bin/solr post -c geonames -type text/csv \
   -params 
'optimize=true&maxSegments=1&separator=%09&encapsulator=%00&fieldnames=id,name,,alternative_names,latitude,longitude,,,countrycode,,,,,,population,elevation,,timezone,lastupdate'
 \
   /tmp/cities1000.txt
 ----


Reply via email to