From 6a7718205df466fc50fc64d758c050c9d925aeb5 Mon Sep 17 00:00:00 2001 From: Andres Rodriguez Date: Tue, 16 Feb 2021 10:30:54 -0500 Subject: [PATCH 1/6] Add example under hosts setting Adds an example under hosts setting showing users how to use an environment variable with multiple white-space delimited hosts. --- docs/index.asciidoc | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/docs/index.asciidoc b/docs/index.asciidoc index ddb0141d5..54849898c 100644 --- a/docs/index.asciidoc +++ b/docs/index.asciidoc @@ -523,6 +523,13 @@ should reference only data or client nodes in Elasticsearch. Any special characters present in the URLs here MUST be URL escaped! This means `#` should be put in as `%23` for instance. +This setting supports defining an environment variable `hosts => '${ES_HOSTS:}', +with multiple {logstash-ref}/plugin-concepts.html[whitespace-delimited URIs], e.g.: + +``` +ES_HOSTS="es1.example.com es2.example.com:9201 es3.example.com:9201" +``` + [id="plugins-{type}s-{plugin}-http_compression"] ===== `http_compression` From 892a26b3081f08eb302694de662f93b8bdd6dfae Mon Sep 17 00:00:00 2001 From: Andres Rodriguez Date: Tue, 16 Feb 2021 11:45:59 -0500 Subject: [PATCH 2/6] Update index.asciidoc --- docs/index.asciidoc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/index.asciidoc b/docs/index.asciidoc index 54849898c..569f2cb5c 100644 --- a/docs/index.asciidoc +++ b/docs/index.asciidoc @@ -523,8 +523,8 @@ should reference only data or client nodes in Elasticsearch. Any special characters present in the URLs here MUST be URL escaped! This means `#` should be put in as `%23` for instance. -This setting supports defining an environment variable `hosts => '${ES_HOSTS:}', -with multiple {logstash-ref}/plugin-concepts.html[whitespace-delimited URIs], e.g.: +Whem using Logstash 7.9+, this setting supports defining an environment variable +`hosts => '${ES_HOSTS:}' with multiple {logstash-ref}/plugin-concepts.html[whitespace-delimited URIs], e.g.: ``` ES_HOSTS="es1.example.com es2.example.com:9201 es3.example.com:9201" From acb3e23ec5430d7d569da518d6b9f30a537f204b Mon Sep 17 00:00:00 2001 From: Andres Rodriguez Date: Tue, 16 Feb 2021 11:46:29 -0500 Subject: [PATCH 3/6] Update index.asciidoc --- docs/index.asciidoc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/index.asciidoc b/docs/index.asciidoc index 569f2cb5c..f918ef909 100644 --- a/docs/index.asciidoc +++ b/docs/index.asciidoc @@ -523,7 +523,7 @@ should reference only data or client nodes in Elasticsearch. Any special characters present in the URLs here MUST be URL escaped! This means `#` should be put in as `%23` for instance. -Whem using Logstash 7.9+, this setting supports defining an environment variable +When using Logstash 7.9+, this setting supports defining an environment variable `hosts => '${ES_HOSTS:}' with multiple {logstash-ref}/plugin-concepts.html[whitespace-delimited URIs], e.g.: ``` From 0138f1ea11be484434ac0874bb2d9b24229fef43 Mon Sep 17 00:00:00 2001 From: Andres Rodriguez Date: Thu, 18 Feb 2021 16:17:14 -0500 Subject: [PATCH 4/6] Update index.asciidoc --- docs/index.asciidoc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/index.asciidoc b/docs/index.asciidoc index f918ef909..9f838d7a0 100644 --- a/docs/index.asciidoc +++ b/docs/index.asciidoc @@ -524,7 +524,7 @@ Any special characters present in the URLs here MUST be URL escaped! This means `#` should be put in as `%23` for instance. When using Logstash 7.9+, this setting supports defining an environment variable -`hosts => '${ES_HOSTS:}' with multiple {logstash-ref}/plugin-concepts.html[whitespace-delimited URIs], e.g.: +`hosts => '${ES_HOSTS:}' with multiple {logstash-ref}/plugin-concepts.html#space-delimited-uris-in-list-params[whitespace-delimited URIs], e.g.: ``` ES_HOSTS="es1.example.com es2.example.com:9201 es3.example.com:9201" From 9350fa710787b786b2e5eeb337a2546415d70fb5 Mon Sep 17 00:00:00 2001 From: Andres Rodriguez Date: Thu, 18 Feb 2021 16:25:30 -0500 Subject: [PATCH 5/6] Update index.asciidoc --- docs/index.asciidoc | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/docs/index.asciidoc b/docs/index.asciidoc index 9f838d7a0..64194a590 100644 --- a/docs/index.asciidoc +++ b/docs/index.asciidoc @@ -524,11 +524,14 @@ Any special characters present in the URLs here MUST be URL escaped! This means `#` should be put in as `%23` for instance. When using Logstash 7.9+, this setting supports defining an environment variable -`hosts => '${ES_HOSTS:}' with multiple {logstash-ref}/plugin-concepts.html#space-delimited-uris-in-list-params[whitespace-delimited URIs], e.g.: +`hosts => '${S}'` with multiple {logstash-ref}/plugin-concepts.html#space-delimited-uris-in-list-params[whitespace-delimited URIs]: -``` -ES_HOSTS="es1.example.com es2.example.com:9201 es3.example.com:9201" -``` +Examples: + + `ES_HOSTS="es1.example.com es2.example.com:9201 es3.example.com:9201"` + `ES_HOSTS="127.0.0.1:9200 127.0.0.2:9200"` + `ES_HOSTS="http://127.0.0.1 http://127.0.0.2"` + `ES_HOSTS="https://127.0.0.1:9200/mypath https://127.0.0.2:9200/mypath"` [id="plugins-{type}s-{plugin}-http_compression"] ===== `http_compression` From f9fdce41558db93bbbfcab57bd198386a31d36e2 Mon Sep 17 00:00:00 2001 From: Andres Rodriguez Date: Mon, 26 Sep 2022 16:43:10 -0400 Subject: [PATCH 6/6] Update docs/index.asciidoc Co-authored-by: Karen Metts <35154725+karenzone@users.noreply.github.com> --- docs/index.asciidoc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/index.asciidoc b/docs/index.asciidoc index 64194a590..7b9b0f8bc 100644 --- a/docs/index.asciidoc +++ b/docs/index.asciidoc @@ -523,8 +523,8 @@ should reference only data or client nodes in Elasticsearch. Any special characters present in the URLs here MUST be URL escaped! This means `#` should be put in as `%23` for instance. -When using Logstash 7.9+, this setting supports defining an environment variable -`hosts => '${S}'` with multiple {logstash-ref}/plugin-concepts.html#space-delimited-uris-in-list-params[whitespace-delimited URIs]: +This option can accept an environment variable containing one or more hostnames separated by whitespace. +Strings separated by whitespace are treated as separate entries. Examples: