elasticsearch 8.17.1__py3-none-any.whl → 8.17.2__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- elasticsearch/__init__.py +2 -2
- elasticsearch/_async/client/__init__.py +1971 -779
- elasticsearch/_async/client/async_search.py +33 -22
- elasticsearch/_async/client/autoscaling.py +27 -21
- elasticsearch/_async/client/cat.py +216 -141
- elasticsearch/_async/client/ccr.py +96 -70
- elasticsearch/_async/client/cluster.py +150 -142
- elasticsearch/_async/client/connector.py +182 -86
- elasticsearch/_async/client/dangling_indices.py +19 -13
- elasticsearch/_async/client/enrich.py +25 -6
- elasticsearch/_async/client/eql.py +22 -9
- elasticsearch/_async/client/esql.py +295 -3
- elasticsearch/_async/client/features.py +25 -25
- elasticsearch/_async/client/fleet.py +15 -9
- elasticsearch/_async/client/graph.py +9 -8
- elasticsearch/_async/client/ilm.py +85 -55
- elasticsearch/_async/client/indices.py +692 -549
- elasticsearch/_async/client/inference.py +32 -28
- elasticsearch/_async/client/ingest.py +61 -22
- elasticsearch/_async/client/license.py +48 -31
- elasticsearch/_async/client/logstash.py +17 -6
- elasticsearch/_async/client/migration.py +23 -14
- elasticsearch/_async/client/ml.py +532 -284
- elasticsearch/_async/client/monitoring.py +5 -2
- elasticsearch/_async/client/nodes.py +43 -27
- elasticsearch/_async/client/query_rules.py +51 -25
- elasticsearch/_async/client/rollup.py +111 -73
- elasticsearch/_async/client/search_application.py +49 -21
- elasticsearch/_async/client/searchable_snapshots.py +21 -8
- elasticsearch/_async/client/security.py +810 -472
- elasticsearch/_async/client/shutdown.py +31 -26
- elasticsearch/_async/client/simulate.py +16 -22
- elasticsearch/_async/client/slm.py +55 -30
- elasticsearch/_async/client/snapshot.py +173 -192
- elasticsearch/_async/client/sql.py +37 -16
- elasticsearch/_async/client/ssl.py +16 -17
- elasticsearch/_async/client/synonyms.py +50 -29
- elasticsearch/_async/client/tasks.py +74 -39
- elasticsearch/_async/client/text_structure.py +61 -52
- elasticsearch/_async/client/transform.py +108 -79
- elasticsearch/_async/client/watcher.py +93 -57
- elasticsearch/_async/client/xpack.py +16 -7
- elasticsearch/_async/helpers.py +1 -1
- elasticsearch/_sync/client/__init__.py +1971 -779
- elasticsearch/_sync/client/async_search.py +33 -22
- elasticsearch/_sync/client/autoscaling.py +27 -21
- elasticsearch/_sync/client/cat.py +216 -141
- elasticsearch/_sync/client/ccr.py +96 -70
- elasticsearch/_sync/client/cluster.py +150 -142
- elasticsearch/_sync/client/connector.py +182 -86
- elasticsearch/_sync/client/dangling_indices.py +19 -13
- elasticsearch/_sync/client/enrich.py +25 -6
- elasticsearch/_sync/client/eql.py +22 -9
- elasticsearch/_sync/client/esql.py +295 -3
- elasticsearch/_sync/client/features.py +25 -25
- elasticsearch/_sync/client/fleet.py +15 -9
- elasticsearch/_sync/client/graph.py +9 -8
- elasticsearch/_sync/client/ilm.py +85 -55
- elasticsearch/_sync/client/indices.py +692 -549
- elasticsearch/_sync/client/inference.py +32 -28
- elasticsearch/_sync/client/ingest.py +61 -22
- elasticsearch/_sync/client/license.py +48 -31
- elasticsearch/_sync/client/logstash.py +17 -6
- elasticsearch/_sync/client/migration.py +23 -14
- elasticsearch/_sync/client/ml.py +532 -284
- elasticsearch/_sync/client/monitoring.py +5 -2
- elasticsearch/_sync/client/nodes.py +43 -27
- elasticsearch/_sync/client/query_rules.py +51 -25
- elasticsearch/_sync/client/rollup.py +111 -73
- elasticsearch/_sync/client/search_application.py +49 -21
- elasticsearch/_sync/client/searchable_snapshots.py +21 -8
- elasticsearch/_sync/client/security.py +810 -472
- elasticsearch/_sync/client/shutdown.py +31 -26
- elasticsearch/_sync/client/simulate.py +16 -22
- elasticsearch/_sync/client/slm.py +55 -30
- elasticsearch/_sync/client/snapshot.py +173 -192
- elasticsearch/_sync/client/sql.py +37 -16
- elasticsearch/_sync/client/ssl.py +16 -17
- elasticsearch/_sync/client/synonyms.py +50 -29
- elasticsearch/_sync/client/tasks.py +74 -39
- elasticsearch/_sync/client/text_structure.py +61 -52
- elasticsearch/_sync/client/transform.py +108 -79
- elasticsearch/_sync/client/utils.py +1 -1
- elasticsearch/_sync/client/watcher.py +93 -57
- elasticsearch/_sync/client/xpack.py +16 -7
- elasticsearch/_version.py +1 -1
- elasticsearch/client.py +2 -0
- elasticsearch/helpers/actions.py +1 -1
- elasticsearch/helpers/vectorstore/_sync/vectorstore.py +4 -1
- {elasticsearch-8.17.1.dist-info → elasticsearch-8.17.2.dist-info}/METADATA +1 -1
- elasticsearch-8.17.2.dist-info/RECORD +119 -0
- elasticsearch-8.17.1.dist-info/RECORD +0 -119
- {elasticsearch-8.17.1.dist-info → elasticsearch-8.17.2.dist-info}/WHEEL +0 -0
- {elasticsearch-8.17.1.dist-info → elasticsearch-8.17.2.dist-info}/licenses/LICENSE +0 -0
- {elasticsearch-8.17.1.dist-info → elasticsearch-8.17.2.dist-info}/licenses/NOTICE +0 -0
|
@@ -39,7 +39,11 @@ class TransformClient(NamespacedClient):
|
|
|
39
39
|
timeout: t.Optional[t.Union[str, t.Literal[-1], t.Literal[0]]] = None,
|
|
40
40
|
) -> ObjectApiResponse[t.Any]:
|
|
41
41
|
"""
|
|
42
|
-
|
|
42
|
+
.. raw:: html
|
|
43
|
+
|
|
44
|
+
<p>Delete a transform.
|
|
45
|
+
Deletes a transform.</p>
|
|
46
|
+
|
|
43
47
|
|
|
44
48
|
`<https://www.elastic.co/guide/en/elasticsearch/reference/8.17/delete-transform.html>`_
|
|
45
49
|
|
|
@@ -99,7 +103,11 @@ class TransformClient(NamespacedClient):
|
|
|
99
103
|
size: t.Optional[int] = None,
|
|
100
104
|
) -> ObjectApiResponse[t.Any]:
|
|
101
105
|
"""
|
|
102
|
-
|
|
106
|
+
.. raw:: html
|
|
107
|
+
|
|
108
|
+
<p>Get transforms.
|
|
109
|
+
Retrieves configuration information for transforms.</p>
|
|
110
|
+
|
|
103
111
|
|
|
104
112
|
`<https://www.elastic.co/guide/en/elasticsearch/reference/8.17/get-transform.html>`_
|
|
105
113
|
|
|
@@ -168,7 +176,11 @@ class TransformClient(NamespacedClient):
|
|
|
168
176
|
timeout: t.Optional[t.Union[str, t.Literal[-1], t.Literal[0]]] = None,
|
|
169
177
|
) -> ObjectApiResponse[t.Any]:
|
|
170
178
|
"""
|
|
171
|
-
|
|
179
|
+
.. raw:: html
|
|
180
|
+
|
|
181
|
+
<p>Get transform stats.
|
|
182
|
+
Retrieves usage information for transforms.</p>
|
|
183
|
+
|
|
172
184
|
|
|
173
185
|
`<https://www.elastic.co/guide/en/elasticsearch/reference/8.17/get-transform-stats.html>`_
|
|
174
186
|
|
|
@@ -249,12 +261,14 @@ class TransformClient(NamespacedClient):
|
|
|
249
261
|
body: t.Optional[t.Dict[str, t.Any]] = None,
|
|
250
262
|
) -> ObjectApiResponse[t.Any]:
|
|
251
263
|
"""
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
264
|
+
.. raw:: html
|
|
265
|
+
|
|
266
|
+
<p>Preview a transform.
|
|
267
|
+
Generates a preview of the results that you will get when you create a transform with the same configuration.</p>
|
|
268
|
+
<p>It returns a maximum of 100 results. The calculations are based on all the current data in the source index. It also
|
|
269
|
+
generates a list of mappings and settings for the destination index. These values are determined based on the field
|
|
270
|
+
types of the source index and the transform aggregations.</p>
|
|
271
|
+
|
|
258
272
|
|
|
259
273
|
`<https://www.elastic.co/guide/en/elasticsearch/reference/8.17/preview-transform.html>`_
|
|
260
274
|
|
|
@@ -371,27 +385,27 @@ class TransformClient(NamespacedClient):
|
|
|
371
385
|
body: t.Optional[t.Dict[str, t.Any]] = None,
|
|
372
386
|
) -> ObjectApiResponse[t.Any]:
|
|
373
387
|
"""
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
388
|
+
.. raw:: html
|
|
389
|
+
|
|
390
|
+
<p>Create a transform.
|
|
391
|
+
Creates a transform.</p>
|
|
392
|
+
<p>A transform copies data from source indices, transforms it, and persists it into an entity-centric destination index. You can also think of the destination index as a two-dimensional tabular data structure (known as
|
|
393
|
+
a data frame). The ID for each document in the data frame is generated from a hash of the entity, so there is a
|
|
394
|
+
unique row per entity.</p>
|
|
395
|
+
<p>You must choose either the latest or pivot method for your transform; you cannot use both in a single transform. If
|
|
396
|
+
you choose to use the pivot method for your transform, the entities are defined by the set of <code>group_by</code> fields in
|
|
397
|
+
the pivot object. If you choose to use the latest method, the entities are defined by the <code>unique_key</code> field values
|
|
398
|
+
in the latest object.</p>
|
|
399
|
+
<p>You must have <code>create_index</code>, <code>index</code>, and <code>read</code> privileges on the destination index and <code>read</code> and
|
|
400
|
+
<code>view_index_metadata</code> privileges on the source indices. When Elasticsearch security features are enabled, the
|
|
401
|
+
transform remembers which roles the user that created it had at the time of creation and uses those same roles. If
|
|
402
|
+
those roles do not have the required privileges on the source and destination indices, the transform fails when it
|
|
403
|
+
attempts unauthorized operations.</p>
|
|
404
|
+
<p>NOTE: You must use Kibana or this API to create a transform. Do not add a transform directly into any
|
|
405
|
+
<code>.transform-internal*</code> indices using the Elasticsearch index API. If Elasticsearch security features are enabled, do
|
|
406
|
+
not give users any privileges on <code>.transform-internal*</code> indices. If you used transforms prior to 7.5, also do not
|
|
407
|
+
give users any privileges on <code>.data-frame-internal*</code> indices.</p>
|
|
408
|
+
|
|
395
409
|
|
|
396
410
|
`<https://www.elastic.co/guide/en/elasticsearch/reference/8.17/put-transform.html>`_
|
|
397
411
|
|
|
@@ -491,9 +505,13 @@ class TransformClient(NamespacedClient):
|
|
|
491
505
|
pretty: t.Optional[bool] = None,
|
|
492
506
|
) -> ObjectApiResponse[t.Any]:
|
|
493
507
|
"""
|
|
494
|
-
|
|
495
|
-
|
|
496
|
-
|
|
508
|
+
.. raw:: html
|
|
509
|
+
|
|
510
|
+
<p>Reset a transform.
|
|
511
|
+
Resets a transform.
|
|
512
|
+
Before you can reset it, you must stop it; alternatively, use the <code>force</code> query parameter.
|
|
513
|
+
If the destination index was created by the transform, it is deleted.</p>
|
|
514
|
+
|
|
497
515
|
|
|
498
516
|
`<https://www.elastic.co/guide/en/elasticsearch/reference/8.17/reset-transform.html>`_
|
|
499
517
|
|
|
@@ -541,11 +559,15 @@ class TransformClient(NamespacedClient):
|
|
|
541
559
|
timeout: t.Optional[t.Union[str, t.Literal[-1], t.Literal[0]]] = None,
|
|
542
560
|
) -> ObjectApiResponse[t.Any]:
|
|
543
561
|
"""
|
|
544
|
-
|
|
545
|
-
|
|
546
|
-
|
|
547
|
-
|
|
548
|
-
|
|
562
|
+
.. raw:: html
|
|
563
|
+
|
|
564
|
+
<p>Schedule a transform to start now.
|
|
565
|
+
Instantly runs a transform to process data.</p>
|
|
566
|
+
<p>If you _schedule_now a transform, it will process the new data instantly,
|
|
567
|
+
without waiting for the configured frequency interval. After _schedule_now API is called,
|
|
568
|
+
the transform will be processed again at now + frequency unless _schedule_now API
|
|
569
|
+
is called again in the meantime.</p>
|
|
570
|
+
|
|
549
571
|
|
|
550
572
|
`<https://www.elastic.co/guide/en/elasticsearch/reference/8.17/schedule-now-transform.html>`_
|
|
551
573
|
|
|
@@ -592,24 +614,24 @@ class TransformClient(NamespacedClient):
|
|
|
592
614
|
timeout: t.Optional[t.Union[str, t.Literal[-1], t.Literal[0]]] = None,
|
|
593
615
|
) -> ObjectApiResponse[t.Any]:
|
|
594
616
|
"""
|
|
595
|
-
|
|
596
|
-
|
|
597
|
-
|
|
598
|
-
|
|
599
|
-
|
|
600
|
-
|
|
601
|
-
|
|
602
|
-
|
|
603
|
-
|
|
604
|
-
|
|
605
|
-
|
|
606
|
-
|
|
607
|
-
|
|
608
|
-
|
|
609
|
-
|
|
610
|
-
|
|
611
|
-
|
|
612
|
-
|
|
617
|
+
.. raw:: html
|
|
618
|
+
|
|
619
|
+
<p>Start a transform.
|
|
620
|
+
Starts a transform.</p>
|
|
621
|
+
<p>When you start a transform, it creates the destination index if it does not already exist. The <code>number_of_shards</code> is
|
|
622
|
+
set to <code>1</code> and the <code>auto_expand_replicas</code> is set to <code>0-1</code>. If it is a pivot transform, it deduces the mapping
|
|
623
|
+
definitions for the destination index from the source indices and the transform aggregations. If fields in the
|
|
624
|
+
destination index are derived from scripts (as in the case of <code>scripted_metric</code> or <code>bucket_script</code> aggregations),
|
|
625
|
+
the transform uses dynamic mappings unless an index template exists. If it is a latest transform, it does not deduce
|
|
626
|
+
mapping definitions; it uses dynamic mappings. To use explicit mappings, create the destination index before you
|
|
627
|
+
start the transform. Alternatively, you can create an index template, though it does not affect the deduced mappings
|
|
628
|
+
in a pivot transform.</p>
|
|
629
|
+
<p>When the transform starts, a series of validations occur to ensure its success. If you deferred validation when you
|
|
630
|
+
created the transform, they occur when you start the transform—with the exception of privilege checks. When
|
|
631
|
+
Elasticsearch security features are enabled, the transform remembers which roles the user that created it had at the
|
|
632
|
+
time of creation and uses those same roles. If those roles do not have the required privileges on the source and
|
|
633
|
+
destination indices, the transform fails when it attempts unauthorized operations.</p>
|
|
634
|
+
|
|
613
635
|
|
|
614
636
|
`<https://www.elastic.co/guide/en/elasticsearch/reference/8.17/start-transform.html>`_
|
|
615
637
|
|
|
@@ -663,7 +685,11 @@ class TransformClient(NamespacedClient):
|
|
|
663
685
|
wait_for_completion: t.Optional[bool] = None,
|
|
664
686
|
) -> ObjectApiResponse[t.Any]:
|
|
665
687
|
"""
|
|
666
|
-
|
|
688
|
+
.. raw:: html
|
|
689
|
+
|
|
690
|
+
<p>Stop transforms.
|
|
691
|
+
Stops one or more transforms.</p>
|
|
692
|
+
|
|
667
693
|
|
|
668
694
|
`<https://www.elastic.co/guide/en/elasticsearch/reference/8.17/stop-transform.html>`_
|
|
669
695
|
|
|
@@ -756,14 +782,16 @@ class TransformClient(NamespacedClient):
|
|
|
756
782
|
body: t.Optional[t.Dict[str, t.Any]] = None,
|
|
757
783
|
) -> ObjectApiResponse[t.Any]:
|
|
758
784
|
"""
|
|
759
|
-
|
|
760
|
-
|
|
761
|
-
|
|
762
|
-
|
|
763
|
-
|
|
764
|
-
|
|
765
|
-
|
|
766
|
-
|
|
785
|
+
.. raw:: html
|
|
786
|
+
|
|
787
|
+
<p>Update a transform.
|
|
788
|
+
Updates certain properties of a transform.</p>
|
|
789
|
+
<p>All updated properties except <code>description</code> do not take effect until after the transform starts the next checkpoint,
|
|
790
|
+
thus there is data consistency in each checkpoint. To use this API, you must have <code>read</code> and <code>view_index_metadata</code>
|
|
791
|
+
privileges for the source indices. You must also have <code>index</code> and <code>read</code> privileges for the destination index. When
|
|
792
|
+
Elasticsearch security features are enabled, the transform remembers which roles the user who updated it had at the
|
|
793
|
+
time of update and runs with those privileges.</p>
|
|
794
|
+
|
|
767
795
|
|
|
768
796
|
`<https://www.elastic.co/guide/en/elasticsearch/reference/8.17/update-transform.html>`_
|
|
769
797
|
|
|
@@ -844,20 +872,21 @@ class TransformClient(NamespacedClient):
|
|
|
844
872
|
timeout: t.Optional[t.Union[str, t.Literal[-1], t.Literal[0]]] = None,
|
|
845
873
|
) -> ObjectApiResponse[t.Any]:
|
|
846
874
|
"""
|
|
847
|
-
|
|
848
|
-
|
|
849
|
-
|
|
850
|
-
|
|
851
|
-
|
|
852
|
-
|
|
853
|
-
|
|
854
|
-
|
|
855
|
-
|
|
856
|
-
|
|
857
|
-
|
|
858
|
-
|
|
859
|
-
|
|
860
|
-
|
|
875
|
+
.. raw:: html
|
|
876
|
+
|
|
877
|
+
<p>Upgrade all transforms.
|
|
878
|
+
Transforms are compatible across minor versions and between supported major versions.
|
|
879
|
+
However, over time, the format of transform configuration information may change.
|
|
880
|
+
This API identifies transforms that have a legacy configuration format and upgrades them to the latest version.
|
|
881
|
+
It also cleans up the internal data structures that store the transform state and checkpoints.
|
|
882
|
+
The upgrade does not affect the source and destination indices.
|
|
883
|
+
The upgrade also does not affect the roles that transforms use when Elasticsearch security features are enabled; the role used to read source data and write to the destination index remains unchanged.</p>
|
|
884
|
+
<p>If a transform upgrade step fails, the upgrade stops and an error is returned about the underlying issue.
|
|
885
|
+
Resolve the issue then re-run the process again.
|
|
886
|
+
A summary is returned when the upgrade is finished.</p>
|
|
887
|
+
<p>To ensure continuous transforms remain running during a major version upgrade of the cluster – for example, from 7.16 to 8.0 – it is recommended to upgrade transforms before upgrading the cluster.
|
|
888
|
+
You may want to perform a recent cluster backup prior to the upgrade.</p>
|
|
889
|
+
|
|
861
890
|
|
|
862
891
|
`<https://www.elastic.co/guide/en/elasticsearch/reference/8.17/upgrade-transforms.html>`_
|
|
863
892
|
|
|
@@ -37,14 +37,16 @@ class WatcherClient(NamespacedClient):
|
|
|
37
37
|
pretty: t.Optional[bool] = None,
|
|
38
38
|
) -> ObjectApiResponse[t.Any]:
|
|
39
39
|
"""
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
40
|
+
.. raw:: html
|
|
41
|
+
|
|
42
|
+
<p>Acknowledge a watch.
|
|
43
|
+
Acknowledging a watch enables you to manually throttle the execution of the watch's actions.</p>
|
|
44
|
+
<p>The acknowledgement state of an action is stored in the <code>status.actions.<id>.ack.state</code> structure.</p>
|
|
45
|
+
<p>IMPORTANT: If the specified watch is currently being executed, this API will return an error
|
|
46
|
+
The reason for this behavior is to prevent overwriting the watch status from a watch execution.</p>
|
|
47
|
+
<p>Acknowledging an action throttles further executions of that action until its <code>ack.state</code> is reset to <code>awaits_successful_execution</code>.
|
|
48
|
+
This happens when the condition of the watch is not met (the condition evaluates to false).</p>
|
|
49
|
+
|
|
48
50
|
|
|
49
51
|
`<https://www.elastic.co/guide/en/elasticsearch/reference/8.17/watcher-api-ack-watch.html>`_
|
|
50
52
|
|
|
@@ -96,7 +98,11 @@ class WatcherClient(NamespacedClient):
|
|
|
96
98
|
pretty: t.Optional[bool] = None,
|
|
97
99
|
) -> ObjectApiResponse[t.Any]:
|
|
98
100
|
"""
|
|
99
|
-
|
|
101
|
+
.. raw:: html
|
|
102
|
+
|
|
103
|
+
<p>Activate a watch.
|
|
104
|
+
A watch can be either active or inactive.</p>
|
|
105
|
+
|
|
100
106
|
|
|
101
107
|
`<https://www.elastic.co/guide/en/elasticsearch/reference/8.17/watcher-api-activate-watch.html>`_
|
|
102
108
|
|
|
@@ -136,7 +142,11 @@ class WatcherClient(NamespacedClient):
|
|
|
136
142
|
pretty: t.Optional[bool] = None,
|
|
137
143
|
) -> ObjectApiResponse[t.Any]:
|
|
138
144
|
"""
|
|
139
|
-
|
|
145
|
+
.. raw:: html
|
|
146
|
+
|
|
147
|
+
<p>Deactivate a watch.
|
|
148
|
+
A watch can be either active or inactive.</p>
|
|
149
|
+
|
|
140
150
|
|
|
141
151
|
`<https://www.elastic.co/guide/en/elasticsearch/reference/8.17/watcher-api-deactivate-watch.html>`_
|
|
142
152
|
|
|
@@ -176,13 +186,15 @@ class WatcherClient(NamespacedClient):
|
|
|
176
186
|
pretty: t.Optional[bool] = None,
|
|
177
187
|
) -> ObjectApiResponse[t.Any]:
|
|
178
188
|
"""
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
189
|
+
.. raw:: html
|
|
190
|
+
|
|
191
|
+
<p>Delete a watch.
|
|
192
|
+
When the watch is removed, the document representing the watch in the <code>.watches</code> index is gone and it will never be run again.</p>
|
|
193
|
+
<p>Deleting a watch does not delete any watch execution records related to this watch from the watch history.</p>
|
|
194
|
+
<p>IMPORTANT: Deleting a watch must be done by using only this API.
|
|
195
|
+
Do not delete the watch directly from the <code>.watches</code> index using the Elasticsearch delete document API
|
|
196
|
+
When Elasticsearch security features are enabled, make sure no write privileges are granted to anyone for the <code>.watches</code> index.</p>
|
|
197
|
+
|
|
186
198
|
|
|
187
199
|
`<https://www.elastic.co/guide/en/elasticsearch/reference/8.17/watcher-api-delete-watch.html>`_
|
|
188
200
|
|
|
@@ -251,21 +263,19 @@ class WatcherClient(NamespacedClient):
|
|
|
251
263
|
body: t.Optional[t.Dict[str, t.Any]] = None,
|
|
252
264
|
) -> ObjectApiResponse[t.Any]:
|
|
253
265
|
"""
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
that called the API will be used as a base, instead of the information who stored
|
|
268
|
-
the watch.
|
|
266
|
+
.. raw:: html
|
|
267
|
+
|
|
268
|
+
<p>Run a watch.
|
|
269
|
+
This API can be used to force execution of the watch outside of its triggering logic or to simulate the watch execution for debugging purposes.</p>
|
|
270
|
+
<p>For testing and debugging purposes, you also have fine-grained control on how the watch runs.
|
|
271
|
+
You can run the watch without running all of its actions or alternatively by simulating them.
|
|
272
|
+
You can also force execution by ignoring the watch condition and control whether a watch record would be written to the watch history after it runs.</p>
|
|
273
|
+
<p>You can use the run watch API to run watches that are not yet registered by specifying the watch definition inline.
|
|
274
|
+
This serves as great tool for testing and debugging your watches prior to adding them to Watcher.</p>
|
|
275
|
+
<p>When Elasticsearch security features are enabled on your cluster, watches are run with the privileges of the user that stored the watches.
|
|
276
|
+
If your user is allowed to read index <code>a</code>, but not index <code>b</code>, then the exact same set of rules will apply during execution of a watch.</p>
|
|
277
|
+
<p>When using the run watch API, the authorization data of the user that called the API will be used as a base, instead of the information who stored the watch.</p>
|
|
278
|
+
|
|
269
279
|
|
|
270
280
|
`<https://www.elastic.co/guide/en/elasticsearch/reference/8.17/watcher-api-execute-watch.html>`_
|
|
271
281
|
|
|
@@ -348,9 +358,12 @@ class WatcherClient(NamespacedClient):
|
|
|
348
358
|
pretty: t.Optional[bool] = None,
|
|
349
359
|
) -> ObjectApiResponse[t.Any]:
|
|
350
360
|
"""
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
361
|
+
.. raw:: html
|
|
362
|
+
|
|
363
|
+
<p>Get Watcher index settings.
|
|
364
|
+
Get settings for the Watcher internal index (<code>.watches</code>).
|
|
365
|
+
Only a subset of settings are shown, for example <code>index.auto_expand_replicas</code> and <code>index.number_of_replicas</code>.</p>
|
|
366
|
+
|
|
354
367
|
|
|
355
368
|
`<https://www.elastic.co/guide/en/elasticsearch/reference/8.17/watcher-api-get-settings.html>`_
|
|
356
369
|
|
|
@@ -392,7 +405,10 @@ class WatcherClient(NamespacedClient):
|
|
|
392
405
|
pretty: t.Optional[bool] = None,
|
|
393
406
|
) -> ObjectApiResponse[t.Any]:
|
|
394
407
|
"""
|
|
395
|
-
|
|
408
|
+
.. raw:: html
|
|
409
|
+
|
|
410
|
+
<p>Get a watch.</p>
|
|
411
|
+
|
|
396
412
|
|
|
397
413
|
`<https://www.elastic.co/guide/en/elasticsearch/reference/8.17/watcher-api-get-watch.html>`_
|
|
398
414
|
|
|
@@ -456,17 +472,18 @@ class WatcherClient(NamespacedClient):
|
|
|
456
472
|
body: t.Optional[t.Dict[str, t.Any]] = None,
|
|
457
473
|
) -> ObjectApiResponse[t.Any]:
|
|
458
474
|
"""
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
|
|
475
|
+
.. raw:: html
|
|
476
|
+
|
|
477
|
+
<p>Create or update a watch.
|
|
478
|
+
When a watch is registered, a new document that represents the watch is added to the <code>.watches</code> index and its trigger is immediately registered with the relevant trigger engine.
|
|
479
|
+
Typically for the <code>schedule</code> trigger, the scheduler is the trigger engine.</p>
|
|
480
|
+
<p>IMPORTANT: You must use Kibana or this API to create a watch.
|
|
481
|
+
Do not add a watch directly to the <code>.watches</code> index by using the Elasticsearch index API.
|
|
482
|
+
If Elasticsearch security features are enabled, do not give users write privileges on the <code>.watches</code> index.</p>
|
|
483
|
+
<p>When you add a watch you can also define its initial active state by setting the <em>active</em> parameter.</p>
|
|
484
|
+
<p>When Elasticsearch security features are enabled, your watch can index or search only on indices for which the user that stored the watch has privileges.
|
|
485
|
+
If the user is able to read index <code>a</code>, but not index <code>b</code>, the same will apply when the watch runs.</p>
|
|
486
|
+
|
|
470
487
|
|
|
471
488
|
`<https://www.elastic.co/guide/en/elasticsearch/reference/8.17/watcher-api-put-watch.html>`_
|
|
472
489
|
|
|
@@ -574,9 +591,12 @@ class WatcherClient(NamespacedClient):
|
|
|
574
591
|
body: t.Optional[t.Dict[str, t.Any]] = None,
|
|
575
592
|
) -> ObjectApiResponse[t.Any]:
|
|
576
593
|
"""
|
|
577
|
-
|
|
578
|
-
|
|
579
|
-
|
|
594
|
+
.. raw:: html
|
|
595
|
+
|
|
596
|
+
<p>Query watches.
|
|
597
|
+
Get all registered watches in a paginated manner and optionally filter watches by a query.</p>
|
|
598
|
+
<p>Note that only the <code>_id</code> and <code>metadata.*</code> fields are queryable or sortable.</p>
|
|
599
|
+
|
|
580
600
|
|
|
581
601
|
`<https://www.elastic.co/guide/en/elasticsearch/reference/8.17/watcher-api-query-watches.html>`_
|
|
582
602
|
|
|
@@ -646,7 +666,11 @@ class WatcherClient(NamespacedClient):
|
|
|
646
666
|
pretty: t.Optional[bool] = None,
|
|
647
667
|
) -> ObjectApiResponse[t.Any]:
|
|
648
668
|
"""
|
|
649
|
-
|
|
669
|
+
.. raw:: html
|
|
670
|
+
|
|
671
|
+
<p>Start the watch service.
|
|
672
|
+
Start the Watcher service if it is not already running.</p>
|
|
673
|
+
|
|
650
674
|
|
|
651
675
|
`<https://www.elastic.co/guide/en/elasticsearch/reference/8.17/watcher-api-start.html>`_
|
|
652
676
|
"""
|
|
@@ -703,8 +727,12 @@ class WatcherClient(NamespacedClient):
|
|
|
703
727
|
pretty: t.Optional[bool] = None,
|
|
704
728
|
) -> ObjectApiResponse[t.Any]:
|
|
705
729
|
"""
|
|
706
|
-
|
|
707
|
-
|
|
730
|
+
.. raw:: html
|
|
731
|
+
|
|
732
|
+
<p>Get Watcher statistics.
|
|
733
|
+
This API always returns basic metrics.
|
|
734
|
+
You retrieve more metrics by using the metric parameter.</p>
|
|
735
|
+
|
|
708
736
|
|
|
709
737
|
`<https://www.elastic.co/guide/en/elasticsearch/reference/8.17/watcher-api-stats.html>`_
|
|
710
738
|
|
|
@@ -751,7 +779,11 @@ class WatcherClient(NamespacedClient):
|
|
|
751
779
|
pretty: t.Optional[bool] = None,
|
|
752
780
|
) -> ObjectApiResponse[t.Any]:
|
|
753
781
|
"""
|
|
754
|
-
|
|
782
|
+
.. raw:: html
|
|
783
|
+
|
|
784
|
+
<p>Stop the watch service.
|
|
785
|
+
Stop the Watcher service if it is running.</p>
|
|
786
|
+
|
|
755
787
|
|
|
756
788
|
`<https://www.elastic.co/guide/en/elasticsearch/reference/8.17/watcher-api-stop.html>`_
|
|
757
789
|
|
|
@@ -803,9 +835,13 @@ class WatcherClient(NamespacedClient):
|
|
|
803
835
|
body: t.Optional[t.Dict[str, t.Any]] = None,
|
|
804
836
|
) -> ObjectApiResponse[t.Any]:
|
|
805
837
|
"""
|
|
806
|
-
|
|
807
|
-
|
|
808
|
-
|
|
838
|
+
.. raw:: html
|
|
839
|
+
|
|
840
|
+
<p>Update Watcher index settings.
|
|
841
|
+
Update settings for the Watcher internal index (<code>.watches</code>).
|
|
842
|
+
Only a subset of settings can be modified.
|
|
843
|
+
This includes <code>index.auto_expand_replicas</code> and <code>index.number_of_replicas</code>.</p>
|
|
844
|
+
|
|
809
845
|
|
|
810
846
|
`<https://www.elastic.co/guide/en/elasticsearch/reference/8.17/watcher-api-update-settings.html>`_
|
|
811
847
|
|
|
@@ -43,10 +43,16 @@ class XPackClient(NamespacedClient):
|
|
|
43
43
|
pretty: t.Optional[bool] = None,
|
|
44
44
|
) -> ObjectApiResponse[t.Any]:
|
|
45
45
|
"""
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
46
|
+
.. raw:: html
|
|
47
|
+
|
|
48
|
+
<p>Get information.
|
|
49
|
+
The information provided by the API includes:</p>
|
|
50
|
+
<ul>
|
|
51
|
+
<li>Build information including the build number and timestamp.</li>
|
|
52
|
+
<li>License information about the currently installed license.</li>
|
|
53
|
+
<li>Feature information for the features that are currently enabled and available under the current license.</li>
|
|
54
|
+
</ul>
|
|
55
|
+
|
|
50
56
|
|
|
51
57
|
`<https://www.elastic.co/guide/en/elasticsearch/reference/8.17/info-api.html>`_
|
|
52
58
|
|
|
@@ -90,9 +96,12 @@ class XPackClient(NamespacedClient):
|
|
|
90
96
|
pretty: t.Optional[bool] = None,
|
|
91
97
|
) -> ObjectApiResponse[t.Any]:
|
|
92
98
|
"""
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
99
|
+
.. raw:: html
|
|
100
|
+
|
|
101
|
+
<p>Get usage information.
|
|
102
|
+
Get information about the features that are currently enabled and available under the current license.
|
|
103
|
+
The API also provides some usage statistics.</p>
|
|
104
|
+
|
|
96
105
|
|
|
97
106
|
`<https://www.elastic.co/guide/en/elasticsearch/reference/8.17/usage-api.html>`_
|
|
98
107
|
|
elasticsearch/_async/helpers.py
CHANGED
|
@@ -257,7 +257,7 @@ async def async_streaming_bulk(
|
|
|
257
257
|
]
|
|
258
258
|
ok: bool
|
|
259
259
|
info: Dict[str, Any]
|
|
260
|
-
async for data, (ok, info) in azip( # type: ignore
|
|
260
|
+
async for data, (ok, info) in azip( # type: ignore[assignment, misc]
|
|
261
261
|
bulk_data,
|
|
262
262
|
_process_bulk_chunk(
|
|
263
263
|
client,
|