Skip to content

Commit 0a93a93

Browse files
javannajrodewig
andauthored
[DOCS] add docs for async search (elastic#53675)
Relates to elastic#49091 Co-Authored-By: James Rodewig <[email protected]>
1 parent 1443ba6 commit 0a93a93

File tree

11 files changed

+267
-35
lines changed

11 files changed

+267
-35
lines changed

buildSrc/src/main/groovy/org/elasticsearch/gradle/doc/RestTestsFromSnippetsTask.groovy

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -314,10 +314,7 @@ class RestTestsFromSnippetsTask extends SnippetsTask {
314314
if (path == null) {
315315
path = '' // Catch requests to the root...
316316
} else {
317-
// Escape some characters that are also escaped by sense
318317
path = path.replace('<', '%3C').replace('>', '%3E')
319-
path = path.replace('{', '%7B').replace('}', '%7D')
320-
path = path.replace('|', '%7C')
321318
}
322319
current.println(" - do:")
323320
if (catchPart != null) {

docs/reference/api-conventions.asciidoc

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ GET /%3Clogstash-%7Bnow%2Fd%7D%3E/_search
8787
}
8888
----------------------------------------------------------------------
8989
// TEST[s/^/PUT logstash-2016.09.20\n/]
90-
// TEST[s/now/2016.09.20||/]
90+
// TEST[s/now/2016.09.20%7C%7C/]
9191

9292
[NOTE]
9393
.Percent encoding of date math characters
@@ -141,7 +141,7 @@ GET /%3Clogstash-%7Bnow%2Fd-2d%7D%3E%2C%3Clogstash-%7Bnow%2Fd-1d%7D%3E%2C%3Clogs
141141
}
142142
----------------------------------------------------------------------
143143
// TEST[s/^/PUT logstash-2016.09.20\nPUT logstash-2016.09.19\nPUT logstash-2016.09.18\n/]
144-
// TEST[s/now/2016.09.20||/]
144+
// TEST[s/now/2016.09.20%7C%7C/]
145145

146146
[[common-options]]
147147
=== Common options
@@ -367,7 +367,7 @@ GET /_search?filter_path=hits.hits._source&_source=title&sort=rating:desc
367367
[float]
368368
==== Flat Settings
369369

370-
The `flat_settings` flag affects rendering of the lists of settings. When the
370+
The `flat_settings` flag affects rendering of the lists of settings. When the
371371
`flat_settings` flag is `true`, settings are returned in a flat format:
372372

373373
[source,console]

docs/reference/async-search.asciidoc

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
[role="xpack"]
2+
[testenv="basic"]
3+
[[async-search-intro]]
4+
== Long-running searches
5+
6+
{es} generally allows you to quickly search across big amounts of data. There are
7+
situations where a search executes on many many shards, possibly against
8+
<<frozen-indices,frozen indices>> and spanning multiple
9+
<<modules-remote-clusters,remote clusters>>, for which
10+
results are not expected to be returned in milliseconds. When you need to
11+
execute long-running searches, synchronously
12+
waiting for its results to be returned is not ideal. Instead, Async search lets
13+
you submit a search request that gets executed _asynchronously_,
14+
monitor the progress of the request, and retrieve results at a later stage.
15+
You can also retrieve partial results as they become available but
16+
before the search has completed.
17+
18+
You can submit an async search request using the <<submit-async-search,submit
19+
async search>> API. The <<get-async-search,get async search>> API allows you to
20+
monitor the progress of an async search request and retrieve its results. An
21+
ongoing async search can be deleted through the <<delete-async-search,delete
22+
async search>> API.

docs/reference/index.asciidoc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,8 @@ include::query-dsl.asciidoc[]
2626

2727
include::modules/cross-cluster-search.asciidoc[]
2828

29+
include::async-search.asciidoc[]
30+
2931
include::scripting.asciidoc[]
3032

3133
include::mapping.asciidoc[]

docs/reference/indices/rollover-index.asciidoc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -300,7 +300,7 @@ POST /logs_write/_rollover <2>
300300
}
301301
}
302302
--------------------------------------------------
303-
// TEST[s/now/2016.10.31||/]
303+
// TEST[s/now/2016.10.31%7C%7C/]
304304

305305
<1> Creates an index named with today's date (e.g.) `logs-2016.10.31-1`
306306
<2> Rolls over to a new index with today's date, e.g. `logs-2016.10.31-000002` if run immediately, or `logs-2016.11.01-000002` if run after 24 hours
@@ -339,7 +339,7 @@ over indices created in the last three days, you could do the following:
339339
GET /%3Clogs-%7Bnow%2Fd%7D-*%3E%2C%3Clogs-%7Bnow%2Fd-1d%7D-*%3E%2C%3Clogs-%7Bnow%2Fd-2d%7D-*%3E/_search
340340
--------------------------------------------------
341341
// TEST[continued]
342-
// TEST[s/now/2016.10.31||/]
342+
// TEST[s/now/2016.10.31%7C%7C/]
343343

344344

345345
[[rollover-index-api-dry-run-ex]]

docs/reference/redirects.asciidoc

Lines changed: 11 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,7 @@ See <<native-realm-configuration>>.
120120
[role="exclude",id="native-settings"]
121121
==== Native realm settings
122122

123-
See <<ref-native-settings>>.
123+
See <<ref-native-settings>>.
124124

125125
[role="exclude",id="configuring-saml-realm"]
126126
=== Configuring a SAML realm
@@ -130,27 +130,27 @@ See <<saml-guide>>.
130130
[role="exclude",id="saml-settings"]
131131
==== SAML realm settings
132132

133-
See <<ref-saml-settings>>.
133+
See <<ref-saml-settings>>.
134134

135135
[role="exclude",id="_saml_realm_signing_settings"]
136136
==== SAML realm signing settings
137137

138-
See <<ref-saml-signing-settings>>.
138+
See <<ref-saml-signing-settings>>.
139139

140140
[role="exclude",id="_saml_realm_encryption_settings"]
141141
==== SAML realm encryption settings
142142

143-
See <<ref-saml-encryption-settings>>.
143+
See <<ref-saml-encryption-settings>>.
144144

145145
[role="exclude",id="_saml_realm_ssl_settings"]
146146
==== SAML realm SSL settings
147147

148-
See <<ref-saml-ssl-settings>>.
148+
See <<ref-saml-ssl-settings>>.
149149

150150
[role="exclude",id="configuring-file-realm"]
151151
=== Configuring a file realm
152152

153-
See <<file-realm-configuration>>.
153+
See <<file-realm-configuration>>.
154154

155155
[role="exclude",id="ldap-user-search"]
156156
=== User search mode and user DN templates mode
@@ -170,7 +170,7 @@ See <<ref-ldap-settings>>.
170170
[role="exclude",id="ldap-ssl"]
171171
=== Setting up SSL between Elasticsearch and LDAP
172172

173-
See <<tls-ldap>>.
173+
See <<tls-ldap>>.
174174

175175
[role="exclude",id="configuring-kerberos-realm"]
176176
=== Configuring a Kerberos realm
@@ -211,7 +211,7 @@ See <<ref-ad-settings>>.
211211
[role="exclude",id="mapping-roles-ad"]
212212
=== Mapping Active Directory users and groups to roles
213213

214-
See <<ad-realm-configuration>>.
214+
See <<ad-realm-configuration>>.
215215

216216
[role="exclude",id="how-security-works"]
217217
=== How security works
@@ -237,9 +237,9 @@ See the details in
237237

238238
This page was deleted.
239239
[[ml-datafeed-chunking-config]]
240-
See the details in <<ml-put-datafeed>>, <<ml-update-datafeed>>,
240+
See the details in <<ml-put-datafeed>>, <<ml-update-datafeed>>,
241241
[[ml-datafeed-delayed-data-check-config]]
242-
<<ml-get-datafeed>>,
242+
<<ml-get-datafeed>>,
243243
[[ml-datafeed-counts]]
244244
<<ml-get-datafeed-stats>>.
245245

@@ -323,7 +323,7 @@ See <<snapshots-register-repository>>.
323323
[role="exclude",id="ml-dfa-analysis-objects"]
324324
=== Analysis configuration objects
325325

326-
This page was deleted.
326+
This page was deleted.
327327
See <<put-dfanalytics>>.
328328

329329
[role="exclude",id="slm-api-delete"]
@@ -376,11 +376,6 @@ See <<slm-api-stop>>.
376376

377377
See <<ccs-gateway-seed-nodes>> and <<ccs-min-roundtrips>>.
378378

379-
[role="exclude",id="async-search"]
380-
=== Asynchronous search
381-
382-
coming::[7.x]
383-
384379
[role="exclude",id="indices-component-templates"]
385380
=== Component template APIs
386381

docs/reference/search.asciidoc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -152,6 +152,8 @@ high). This default value is `5`.
152152

153153
include::search/search.asciidoc[]
154154

155+
include::search/async-search.asciidoc[]
156+
155157
include::search/uri-request.asciidoc[]
156158

157159
include::search/request-body.asciidoc[]

0 commit comments

Comments
 (0)