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 b1ed2d7dbf8f..33449d508c66 100644 --- a/solr/core/src/java/org/apache/solr/cli/PostTool.java +++ b/solr/core/src/java/org/apache/solr/cli/PostTool.java @@ -123,7 +123,7 @@ public class PostTool extends ToolBase { .hasArg() .argName("mode") .desc( - "Which mode the Post tool is running in, 'files' crawls local directory, 'web' crawls website, 'args' processes input args, and 'stdin' reads a command from standard in. default: files.") + "Specifies how to run: 'files' crawls local directories, 'web' crawls websites, 'args' processes positional arguments, and 'stdin' reads standard input stream. Default: files.") .get(); private static final Option RECURSIVE_OPTION = @@ -808,7 +808,7 @@ protected boolean typeSupported(String type) { } static void warn(String msg) { - CLIO.err("PostTool: WARNING: " + msg); + CLIO.err("WARNING: " + msg); } static void info(String msg) { diff --git a/solr/core/src/java/org/apache/solr/cli/StreamTool.java b/solr/core/src/java/org/apache/solr/cli/StreamTool.java index 03e93b7f9162..8ff7aa5a197c 100644 --- a/solr/core/src/java/org/apache/solr/cli/StreamTool.java +++ b/solr/core/src/java/org/apache/solr/cli/StreamTool.java @@ -297,7 +297,7 @@ void runStream( streamContext.getSolrClientCache().close(); } - echoIfVerbose("StreamTool -- Done."); + echoIfVerbose("Done."); } private StreamContext createStreamContext( 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 8743ee2298af..2f8b7f0550bd 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 @@ -86,7 +86,7 @@ solr and solr.cmd::: This is xref:solr-control-script-reference.adoc[Solr's Cont This script is the preferred tool to start and stop Solr. You can also create collections or cores, configure authentication, and work with configuration files when running in SolrCloud mode. -post::: The xref:indexing-guide:post-tool.adoc[], which provides a simple command line interface for POSTing content to Solr. +post::: The xref:indexing-guide:post-command.adoc[], which provides a simple command line interface for POSTing content to Solr. solr.in.sh and solr.in.cmd::: These are property files for *nix and Windows systems, respectively. @@ -147,7 +147,7 @@ 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/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[]. +For more information about using `bin/solr post` with these files, see xref:indexing-guide:post-command.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 db34f483b69f..140b242de8dc 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 @@ -34,7 +34,7 @@ The tutorial assumes that you have Docker installed and running on your computer === Start an external Apache Tika Server -Indexing binary files (PDF, DOCX, PPTX, etc.) with the Post Tool requires the Solr extraction module to be enabled and an external Apache Tika Server to be running. See xref:indexing-guide:indexing-with-tika.adoc#tika-server[Tika Server] for background. We will be running Tika Server using Docker. +Indexing binary files (PDF, DOCX, PPTX, etc.) with the Solr CLI Post command requires the Solr extraction module to be enabled and an external Apache Tika Server to be running. See xref:indexing-guide:indexing-with-tika.adoc#tika-server[Tika Server] for background. We will be running Tika Server using Docker. .Start a Tika Server quickly using Docker (exposes port 9998 on localhost) [,bash] @@ -89,10 +89,10 @@ 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/solr post`:: -If you have a local directory of files, the Post Tool (`bin/solr post`) can index a directory of files. +If you have a local directory of files, the Post command (`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. +We used only JSON, XML and CSV in our exercises, but the Post command can also handle HTML, PDF, Microsoft Office formats (such as MS Word), plain text, and more. + In this example, assume there is a directory named "Documents" locally. To index it, we would issue a command like this (correcting the collection name after the `-c` parameter as needed): @@ -126,7 +126,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/solr post`). +Go ahead and edit any of the existing example data files, change some of the data, and re-run the Post command (`bin/solr post`). You'll see your changes reflected in subsequent searches. === Deleting Data diff --git a/solr/solr-ref-guide/modules/getting-started/pages/tutorial-solrcloud.adoc b/solr/solr-ref-guide/modules/getting-started/pages/tutorial-solrcloud.adoc index 37bf8711b9da..90d215fecef3 100644 --- a/solr/solr-ref-guide/modules/getting-started/pages/tutorial-solrcloud.adoc +++ b/solr/solr-ref-guide/modules/getting-started/pages/tutorial-solrcloud.adoc @@ -151,7 +151,7 @@ $ bin/solr healthcheck -c gettingstarted The healthcheck command gathers basic information about each replica in a collection, such as number of docs, current status (active, down, etc.), and address (where the replica lives in the cluster). -Documents can now be added to SolrCloud using the xref:indexing-guide:post-tool.adoc[]. +Documents can now be added to SolrCloud using the xref:indexing-guide:post-command.adoc[]. To stop Solr in SolrCloud mode, you would use the `bin/solr` script and issue the `stop` command, as in: diff --git a/solr/solr-ref-guide/modules/indexing-guide/indexing-nav.adoc b/solr/solr-ref-guide/modules/indexing-guide/indexing-nav.adoc index 940225e8d4ef..0d8e401eeb59 100644 --- a/solr/solr-ref-guide/modules/indexing-guide/indexing-nav.adoc +++ b/solr/solr-ref-guide/modules/indexing-guide/indexing-nav.adoc @@ -53,7 +53,7 @@ ** xref:indexing-with-cbor.adoc[] ** xref:indexing-with-tika.adoc[] ** xref:indexing-nested-documents.adoc[] -** xref:post-tool.adoc[] +** xref:post-command.adoc[] ** xref:documents-screen.adoc[] ** xref:partial-document-updates.adoc[] ** xref:reindexing.adoc[] diff --git a/solr/solr-ref-guide/modules/indexing-guide/pages/post-tool.adoc b/solr/solr-ref-guide/modules/indexing-guide/pages/post-command.adoc similarity index 94% rename from solr/solr-ref-guide/modules/indexing-guide/pages/post-tool.adoc rename to solr/solr-ref-guide/modules/indexing-guide/pages/post-command.adoc index 76efdd3c9786..9c008b51ab3b 100644 --- a/solr/solr-ref-guide/modules/indexing-guide/pages/post-tool.adoc +++ b/solr/solr-ref-guide/modules/indexing-guide/pages/post-command.adoc @@ -1,4 +1,5 @@ -= Post Tool += Solr CLI Post Command +:page-aliases: post-tool.adoc // Licensed to the Apache Software Foundation (ASF) under one // or more contributor license agreements. See the NOTICE file // distributed with this work for additional information @@ -30,7 +31,7 @@ $ bin/solr post --solr-url http://localhost:8983 --name gettingstarted example/f This will contact the server at `localhost:8983`. The `--help` (or simply `-h`) option will output information on its usage (i.e., `bin/solr post -h)`. -== Using the bin/solr post Tool +== Using the bin/solr post Command 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`. @@ -57,9 +58,9 @@ List of options: xml,json,jsonl,csv,pdf,doc,docx,ppt,pptx,xls,xlsx,odt,odp,ods,ott,otp, ots,rtf,htm,html,txt,log -h,--help Print this message. - --mode Which mode the Post tool is running in, 'files' crawls local - directory, 'web' crawls website, 'args' processes input args, and - 'stdin' reads a command from standard in. default: files. + --mode Specifies how to run: 'files' crawls local directories, 'web' crawls + websites, 'args' processes positional arguments, and 'stdin' reads + standard input stream. Default: files. -o,--optimize Issue an optimize at end of posting documents. --params <=[&=...]> Values must be URL-encoded; these pass through to Solr update request. -r,--recursive For web crawl, how deep to go. default: 1 diff --git a/solr/solr-ref-guide/modules/query-guide/pages/stream-tool.adoc b/solr/solr-ref-guide/modules/query-guide/pages/stream-command.adoc similarity index 94% rename from solr/solr-ref-guide/modules/query-guide/pages/stream-tool.adoc rename to solr/solr-ref-guide/modules/query-guide/pages/stream-command.adoc index 3d4dd842bd86..64b2b369dcdd 100644 --- a/solr/solr-ref-guide/modules/query-guide/pages/stream-tool.adoc +++ b/solr/solr-ref-guide/modules/query-guide/pages/stream-command.adoc @@ -1,4 +1,5 @@ -= Stream Tool += Solr CLI Stream Command +:page-aliases: stream-tool.adoc // Licensed to the Apache Software Foundation (ASF) under one // or more contributor license agreements. See the NOTICE file // distributed with this work for additional information @@ -16,11 +17,11 @@ // specific language governing permissions and limitations // under the License. -The Stream tool allows you to run a xref:streaming-expressions.adoc[] in Solr and see the results from the command line. +The Stream command allows you to run a xref:streaming-expressions.adoc[] in Solr and see the results from the command line. It is very similar to the xref:stream-screen.adoc[], but is part of the `bin/solr` CLI. Being a CLI, you can pipe content into it similar to other Unix style tools, as well as run actually RUN many kinds of expressions locally as well. -NOTE: The Stream Tool is classified as "experimental". +NOTE: The Stream command is classified as "experimental". It may change in backwards-incompatible ways as it evolves to cover additional functionality. To run it, open a terminal and enter: @@ -84,7 +85,7 @@ CORSAIR ValueSelect 1GB 184-Pin DDR SDRAM Unbuffered DDR 400 (PC 3200) System Me A-DATA V-Series 1GB 184-Pin DDR SDRAM Unbuffered DDR 400 (PC 3200) System Memory - OEM ---- -== Using the bin/solr stream Tool +== Using the bin/solr stream Command To use the tool you need to provide the streaming expression either inline as the last argument, or provide a file ending in `.expr` that contains the expression. @@ -127,7 +128,7 @@ This section presents several examples. Streaming Expressions by default are executed in the Solr cluster. However there are use cases where you want to interact with data in your local environment, or even run a streaming expression independent of Solr. -The Stream Tool allows you to specify `--execution local` to process the expression in the Solr CLI's JVM. +The Stream command allows you to specify `--execution local` to process the expression in the Solr CLI's JVM. However, "local" processing does not imply a networking sandbox. Many streaming expressions, such as `search` and `update`, will make network requests to remote Solr nodes if configured to do so, even in "local" execution mode. @@ -156,7 +157,7 @@ $ bin/solr stream --execution local --header load_data.expr ---- -The StreamTool adds some Streaming Expressions specifically for local use: +The Stream command adds some Streaming Expressions specifically for local use: * stdin() lets you pipe data directly into the streaming expression. * cat() that allows you to read ANY file on your local system. This is different from the xref:stream-source-reference.adoc#cat[`cat`] operator that runs in Solr that only accesses `$SOLR_HOME/userfiles/`. diff --git a/solr/solr-ref-guide/modules/query-guide/pages/streaming-expressions.adoc b/solr/solr-ref-guide/modules/query-guide/pages/streaming-expressions.adoc index 256c582a17ba..a040a49328e1 100644 --- a/solr/solr-ref-guide/modules/query-guide/pages/streaming-expressions.adoc +++ b/solr/solr-ref-guide/modules/query-guide/pages/streaming-expressions.adoc @@ -153,6 +153,6 @@ The xref:math-expressions.adoc[] has in depth coverage of visualization techniqu * xref:stream-screen.adoc[]: Submit streaming expressions and see results and parsing explanations. -=== Stream Tool +=== Stream Command -* xref:stream-tool.adoc[]: Submit streaming expressions and see results via `bin/solr stream`. +* xref:stream-command.adoc[]: Submit streaming expressions and see results via `bin/solr stream`. diff --git a/solr/solr-ref-guide/modules/query-guide/querying-nav.adoc b/solr/solr-ref-guide/modules/query-guide/querying-nav.adoc index 6d6ef6f5ca1c..9153c09e1e7a 100644 --- a/solr/solr-ref-guide/modules/query-guide/querying-nav.adoc +++ b/solr/solr-ref-guide/modules/query-guide/querying-nav.adoc @@ -102,4 +102,4 @@ ** xref:graph-traversal.adoc[] ** xref:stream-api.adoc[] ** xref:stream-screen.adoc[] -** xref:stream-tool.adoc[] +** xref:stream-command.adoc[]