@@ -42,7 +42,7 @@ async def delete(
42
42
43
43
`<https://www.elastic.co/guide/en/elasticsearch/reference/master/async-search.html>`_
44
44
45
- :param id: The async search ID
45
+ :param id: A unique identifier for the async search.
46
46
"""
47
47
if id in SKIP_IN_PATH :
48
48
raise ValueError ("Empty value passed for parameter 'id'" )
@@ -84,13 +84,21 @@ async def get(
84
84
85
85
`<https://www.elastic.co/guide/en/elasticsearch/reference/master/async-search.html>`_
86
86
87
- :param id: The async search ID
88
- :param keep_alive: Specify the time interval in which the results (partial or
89
- final) for this search will be available
87
+ :param id: A unique identifier for the async search.
88
+ :param keep_alive: Specifies how long the async search should be available in
89
+ the cluster. When not specified, the `keep_alive` set with the corresponding
90
+ submit async request will be used. Otherwise, it is possible to override
91
+ the value and extend the validity of the request. When this period expires,
92
+ the search, if still running, is cancelled. If the search is completed, its
93
+ saved results are deleted.
90
94
:param typed_keys: Specify whether aggregation and suggester names should be
91
95
prefixed by their respective types in the response
92
- :param wait_for_completion_timeout: Specify the time that the request should
93
- block waiting for the final response
96
+ :param wait_for_completion_timeout: Specifies to wait for the search to be completed
97
+ up until the provided timeout. Final results will be returned if available
98
+ before the timeout expires, otherwise the currently available results will
99
+ be returned once the timeout expires. By default no timeout is set meaning
100
+ that the currently available results will be returned without any additional
101
+ wait.
94
102
"""
95
103
if id in SKIP_IN_PATH :
96
104
raise ValueError ("Empty value passed for parameter 'id'" )
@@ -133,7 +141,7 @@ async def status(
133
141
134
142
`<https://www.elastic.co/guide/en/elasticsearch/reference/master/async-search.html>`_
135
143
136
- :param id: The async search ID
144
+ :param id: A unique identifier for the async search.
137
145
"""
138
146
if id in SKIP_IN_PATH :
139
147
raise ValueError ("Empty value passed for parameter 'id'" )
@@ -316,10 +324,11 @@ async def submit(
316
324
:param analyze_wildcard: Specify whether wildcard and prefix queries should be
317
325
analyzed (default: false)
318
326
:param analyzer: The analyzer to use for the query string
319
- :param batched_reduce_size: The number of shard results that should be reduced
320
- at once on the coordinating node. This value should be used as the granularity
321
- at which progress results will be made available.
322
- :param ccs_minimize_roundtrips:
327
+ :param batched_reduce_size: Affects how often partial results become available,
328
+ which happens whenever shard results are reduced. A partial reduction is
329
+ performed every time the coordinating node has received a certain number
330
+ of new shard responses (5 by default).
331
+ :param ccs_minimize_roundtrips: The default value is the only supported value.
323
332
:param collapse:
324
333
:param default_operator: The default operator for query string query (AND or
325
334
OR)
@@ -344,11 +353,11 @@ async def submit(
344
353
:param ignore_unavailable: Whether specified concrete indices should be ignored
345
354
when unavailable (missing or closed)
346
355
:param indices_boost: Boosts the _score of documents from specified indices.
347
- :param keep_alive: Update the time interval in which the results (partial or
348
- final) for this search will be available
349
- :param keep_on_completion: Control whether the response should be stored in the
350
- cluster if it completed within the provided [wait_for_completion] time (default:
351
- false)
356
+ :param keep_alive: Specifies how long the async search needs to be available.
357
+ Ongoing async searches and any saved search results are deleted after this
358
+ period.
359
+ :param keep_on_completion: If `true`, results are stored for later retrieval
360
+ when the search completes within the `wait_for_completion_timeout`.
352
361
:param knn: Defines the approximate kNN search to run.
353
362
:param lenient: Specify whether format-based query failures (such as providing
354
363
text to a numeric field) should be ignored
@@ -362,7 +371,10 @@ async def submit(
362
371
:param pit: Limits the search to a point in time (PIT). If you provide a PIT,
363
372
you cannot specify an <index> in the request path.
364
373
:param post_filter:
365
- :param pre_filter_shard_size:
374
+ :param pre_filter_shard_size: The default value cannot be changed, which enforces
375
+ the execution of a pre-filter roundtrip to retrieve statistics from each
376
+ shard so that the ones that surely don’t hold any document matching the query
377
+ get skipped.
366
378
:param preference: Specify the node or shard the operation should be performed
367
379
on (default: random)
368
380
:param profile:
@@ -422,8 +434,9 @@ async def submit(
422
434
:param typed_keys: Specify whether aggregation and suggester names should be
423
435
prefixed by their respective types in the response
424
436
:param version: If true, returns document version as part of a hit.
425
- :param wait_for_completion_timeout: Specify the time that the request should
426
- block waiting for the final response
437
+ :param wait_for_completion_timeout: Blocks and waits until the search is completed
438
+ up to a certain timeout. When the async search completes within the timeout,
439
+ the response won’t include the ID as the results are not stored in the cluster.
427
440
"""
428
441
if index not in SKIP_IN_PATH :
429
442
__path = f"/{ _quote (index )} /_async_search"
0 commit comments