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
|
@@ -35,23 +35,22 @@ class SslClient(NamespacedClient):
|
|
|
35
35
|
pretty: t.Optional[bool] = None,
|
|
36
36
|
) -> ObjectApiResponse[t.Any]:
|
|
37
37
|
"""
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
certificates might not be in active use within the cluster.
|
|
38
|
+
.. raw:: html
|
|
39
|
+
|
|
40
|
+
<p>Get SSL certificates.</p>
|
|
41
|
+
<p>Get information about the X.509 certificates that are used to encrypt communications in the cluster.
|
|
42
|
+
The API returns a list that includes certificates from all TLS contexts including:</p>
|
|
43
|
+
<ul>
|
|
44
|
+
<li>Settings for transport and HTTP interfaces</li>
|
|
45
|
+
<li>TLS settings that are used within authentication realms</li>
|
|
46
|
+
<li>TLS settings for remote monitoring exporters</li>
|
|
47
|
+
</ul>
|
|
48
|
+
<p>The list includes certificates that are used for configuring trust, such as those configured in the <code>xpack.security.transport.ssl.truststore</code> and <code>xpack.security.transport.ssl.certificate_authorities</code> settings.
|
|
49
|
+
It also includes certificates that are used for configuring server identity, such as <code>xpack.security.http.ssl.keystore</code> and <code>xpack.security.http.ssl.certificate settings</code>.</p>
|
|
50
|
+
<p>The list does not include certificates that are sourced from the default SSL context of the Java Runtime Environment (JRE), even if those certificates are in use within Elasticsearch.</p>
|
|
51
|
+
<p>NOTE: When a PKCS#11 token is configured as the truststore of the JRE, the API returns all the certificates that are included in the PKCS#11 token irrespective of whether these are used in the Elasticsearch TLS configuration.</p>
|
|
52
|
+
<p>If Elasticsearch is configured to use a keystore or truststore, the API output includes all certificates in that store, even though some of the certificates might not be in active use within the cluster.</p>
|
|
53
|
+
|
|
55
54
|
|
|
56
55
|
`<https://www.elastic.co/guide/en/elasticsearch/reference/8.17/security-api-ssl.html>`_
|
|
57
56
|
"""
|
|
@@ -36,21 +36,22 @@ class SynonymsClient(NamespacedClient):
|
|
|
36
36
|
pretty: t.Optional[bool] = None,
|
|
37
37
|
) -> ObjectApiResponse[t.Any]:
|
|
38
38
|
"""
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
39
|
+
.. raw:: html
|
|
40
|
+
|
|
41
|
+
<p>Delete a synonym set.</p>
|
|
42
|
+
<p>You can only delete a synonyms set that is not in use by any index analyzer.</p>
|
|
43
|
+
<p>Synonyms sets can be used in synonym graph token filters and synonym token filters.
|
|
44
|
+
These synonym filters can be used as part of search analyzers.</p>
|
|
45
|
+
<p>Analyzers need to be loaded when an index is restored (such as when a node starts, or the index becomes open).
|
|
46
|
+
Even if the analyzer is not used on any field mapping, it still needs to be loaded on the index recovery phase.</p>
|
|
47
|
+
<p>If any analyzers cannot be loaded, the index becomes unavailable and the cluster status becomes red or yellow as index shards are not available.
|
|
48
|
+
To prevent that, synonyms sets that are used in analyzers can't be deleted.
|
|
49
|
+
A delete request in this case will return a 400 response code.</p>
|
|
50
|
+
<p>To remove a synonyms set, you must first remove all indices that contain analyzers using it.
|
|
51
|
+
You can migrate an index by creating a new index that does not contain the token filter with the synonyms set, and use the reindex API in order to copy over the index data.
|
|
52
|
+
Once finished, you can delete the index.
|
|
53
|
+
When the synonyms set is not used in analyzers, you will be able to delete it.</p>
|
|
54
|
+
|
|
54
55
|
|
|
55
56
|
`<https://www.elastic.co/guide/en/elasticsearch/reference/8.17/delete-synonyms-set.html>`_
|
|
56
57
|
|
|
@@ -91,7 +92,11 @@ class SynonymsClient(NamespacedClient):
|
|
|
91
92
|
pretty: t.Optional[bool] = None,
|
|
92
93
|
) -> ObjectApiResponse[t.Any]:
|
|
93
94
|
"""
|
|
94
|
-
|
|
95
|
+
.. raw:: html
|
|
96
|
+
|
|
97
|
+
<p>Delete a synonym rule.
|
|
98
|
+
Delete a synonym rule from a synonym set.</p>
|
|
99
|
+
|
|
95
100
|
|
|
96
101
|
`<https://www.elastic.co/guide/en/elasticsearch/reference/8.17/delete-synonym-rule.html>`_
|
|
97
102
|
|
|
@@ -141,7 +146,10 @@ class SynonymsClient(NamespacedClient):
|
|
|
141
146
|
size: t.Optional[int] = None,
|
|
142
147
|
) -> ObjectApiResponse[t.Any]:
|
|
143
148
|
"""
|
|
144
|
-
|
|
149
|
+
.. raw:: html
|
|
150
|
+
|
|
151
|
+
<p>Get a synonym set.</p>
|
|
152
|
+
|
|
145
153
|
|
|
146
154
|
`<https://www.elastic.co/guide/en/elasticsearch/reference/8.17/get-synonyms-set.html>`_
|
|
147
155
|
|
|
@@ -188,7 +196,11 @@ class SynonymsClient(NamespacedClient):
|
|
|
188
196
|
pretty: t.Optional[bool] = None,
|
|
189
197
|
) -> ObjectApiResponse[t.Any]:
|
|
190
198
|
"""
|
|
191
|
-
|
|
199
|
+
.. raw:: html
|
|
200
|
+
|
|
201
|
+
<p>Get a synonym rule.
|
|
202
|
+
Get a synonym rule from a synonym set.</p>
|
|
203
|
+
|
|
192
204
|
|
|
193
205
|
`<https://www.elastic.co/guide/en/elasticsearch/reference/8.17/get-synonym-rule.html>`_
|
|
194
206
|
|
|
@@ -237,7 +249,11 @@ class SynonymsClient(NamespacedClient):
|
|
|
237
249
|
size: t.Optional[int] = None,
|
|
238
250
|
) -> ObjectApiResponse[t.Any]:
|
|
239
251
|
"""
|
|
240
|
-
|
|
252
|
+
.. raw:: html
|
|
253
|
+
|
|
254
|
+
<p>Get all synonym sets.
|
|
255
|
+
Get a summary of all defined synonym sets.</p>
|
|
256
|
+
|
|
241
257
|
|
|
242
258
|
`<https://www.elastic.co/guide/en/elasticsearch/reference/8.17/get-synonyms-set.html>`_
|
|
243
259
|
|
|
@@ -286,12 +302,14 @@ class SynonymsClient(NamespacedClient):
|
|
|
286
302
|
body: t.Optional[t.Dict[str, t.Any]] = None,
|
|
287
303
|
) -> ObjectApiResponse[t.Any]:
|
|
288
304
|
"""
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
305
|
+
.. raw:: html
|
|
306
|
+
|
|
307
|
+
<p>Create or update a synonym set.
|
|
308
|
+
Synonyms sets are limited to a maximum of 10,000 synonym rules per set.
|
|
309
|
+
If you need to manage more synonym rules, you can create multiple synonym sets.</p>
|
|
310
|
+
<p>When an existing synonyms set is updated, the search analyzers that use the synonyms set are reloaded automatically for all indices.
|
|
311
|
+
This is equivalent to invoking the reload search analyzers API for all indices that use the synonyms set.</p>
|
|
312
|
+
|
|
295
313
|
|
|
296
314
|
`<https://www.elastic.co/guide/en/elasticsearch/reference/8.17/put-synonyms-set.html>`_
|
|
297
315
|
|
|
@@ -344,10 +362,13 @@ class SynonymsClient(NamespacedClient):
|
|
|
344
362
|
body: t.Optional[t.Dict[str, t.Any]] = None,
|
|
345
363
|
) -> ObjectApiResponse[t.Any]:
|
|
346
364
|
"""
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
365
|
+
.. raw:: html
|
|
366
|
+
|
|
367
|
+
<p>Create or update a synonym rule.
|
|
368
|
+
Create or update a synonym rule in a synonym set.</p>
|
|
369
|
+
<p>If any of the synonym rules included is invalid, the API returns an error.</p>
|
|
370
|
+
<p>When you update a synonym rule, all analyzers using the synonyms set will be reloaded automatically to reflect the new rule.</p>
|
|
371
|
+
|
|
351
372
|
|
|
352
373
|
`<https://www.elastic.co/guide/en/elasticsearch/reference/8.17/put-synonym-rule.html>`_
|
|
353
374
|
|
|
@@ -47,19 +47,18 @@ class TasksClient(NamespacedClient):
|
|
|
47
47
|
wait_for_completion: t.Optional[bool] = None,
|
|
48
48
|
) -> ObjectApiResponse[t.Any]:
|
|
49
49
|
"""
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
instead of completing the cancelled task.
|
|
50
|
+
.. raw:: html
|
|
51
|
+
|
|
52
|
+
<p>Cancel a task.</p>
|
|
53
|
+
<p>WARNING: The task management API is new and should still be considered a beta feature.
|
|
54
|
+
The API may change in ways that are not backwards compatible.</p>
|
|
55
|
+
<p>A task may continue to run for some time after it has been cancelled because it may not be able to safely stop its current activity straight away.
|
|
56
|
+
It is also possible that Elasticsearch must complete its work on other tasks before it can process the cancellation.
|
|
57
|
+
The get task information API will continue to list these cancelled tasks until they complete.
|
|
58
|
+
The cancelled flag in the response indicates that the cancellation command has been processed and the task will stop as soon as possible.</p>
|
|
59
|
+
<p>To troubleshoot why a cancelled task does not complete promptly, use the get task information API with the <code>?detailed</code> parameter to identify the other tasks the system is running.
|
|
60
|
+
You can also use the node hot threads API to obtain detailed information about the work the system is doing instead of completing the cancelled task.</p>
|
|
61
|
+
|
|
63
62
|
|
|
64
63
|
`<https://www.elastic.co/guide/en/elasticsearch/reference/8.17/tasks.html>`_
|
|
65
64
|
|
|
@@ -120,11 +119,14 @@ class TasksClient(NamespacedClient):
|
|
|
120
119
|
wait_for_completion: t.Optional[bool] = None,
|
|
121
120
|
) -> ObjectApiResponse[t.Any]:
|
|
122
121
|
"""
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
122
|
+
.. raw:: html
|
|
123
|
+
|
|
124
|
+
<p>Get task information.
|
|
125
|
+
Get information about a task currently running in the cluster.</p>
|
|
126
|
+
<p>WARNING: The task management API is new and should still be considered a beta feature.
|
|
127
|
+
The API may change in ways that are not backwards compatible.</p>
|
|
128
|
+
<p>If the task identifier is not found, a 404 response code indicates that there are no resources that match the request.</p>
|
|
129
|
+
|
|
128
130
|
|
|
129
131
|
`<https://www.elastic.co/guide/en/elasticsearch/reference/8.17/tasks.html>`_
|
|
130
132
|
|
|
@@ -182,27 +184,60 @@ class TasksClient(NamespacedClient):
|
|
|
182
184
|
wait_for_completion: t.Optional[bool] = None,
|
|
183
185
|
) -> ObjectApiResponse[t.Any]:
|
|
184
186
|
"""
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
187
|
+
.. raw:: html
|
|
188
|
+
|
|
189
|
+
<p>Get all tasks.
|
|
190
|
+
Get information about the tasks currently running on one or more nodes in the cluster.</p>
|
|
191
|
+
<p>WARNING: The task management API is new and should still be considered a beta feature.
|
|
192
|
+
The API may change in ways that are not backwards compatible.</p>
|
|
193
|
+
<p><strong>Identifying running tasks</strong></p>
|
|
194
|
+
<p>The <code>X-Opaque-Id header</code>, when provided on the HTTP request header, is going to be returned as a header in the response as well as in the headers field for in the task information.
|
|
195
|
+
This enables you to track certain calls or associate certain tasks with the client that started them.
|
|
196
|
+
For example:</p>
|
|
197
|
+
<pre><code>curl -i -H "X-Opaque-Id: 123456" "http://localhost:9200/_tasks?group_by=parents"
|
|
198
|
+
</code></pre>
|
|
199
|
+
<p>The API returns the following result:</p>
|
|
200
|
+
<pre><code>HTTP/1.1 200 OK
|
|
201
|
+
X-Opaque-Id: 123456
|
|
202
|
+
content-type: application/json; charset=UTF-8
|
|
203
|
+
content-length: 831
|
|
204
|
+
|
|
205
|
+
{
|
|
206
|
+
"tasks" : {
|
|
207
|
+
"u5lcZHqcQhu-rUoFaqDphA:45" : {
|
|
208
|
+
"node" : "u5lcZHqcQhu-rUoFaqDphA",
|
|
209
|
+
"id" : 45,
|
|
210
|
+
"type" : "transport",
|
|
211
|
+
"action" : "cluster:monitor/tasks/lists",
|
|
212
|
+
"start_time_in_millis" : 1513823752749,
|
|
213
|
+
"running_time_in_nanos" : 293139,
|
|
214
|
+
"cancellable" : false,
|
|
215
|
+
"headers" : {
|
|
216
|
+
"X-Opaque-Id" : "123456"
|
|
217
|
+
},
|
|
218
|
+
"children" : [
|
|
219
|
+
{
|
|
220
|
+
"node" : "u5lcZHqcQhu-rUoFaqDphA",
|
|
221
|
+
"id" : 46,
|
|
222
|
+
"type" : "direct",
|
|
223
|
+
"action" : "cluster:monitor/tasks/lists[n]",
|
|
224
|
+
"start_time_in_millis" : 1513823752750,
|
|
225
|
+
"running_time_in_nanos" : 92133,
|
|
226
|
+
"cancellable" : false,
|
|
227
|
+
"parent_task_id" : "u5lcZHqcQhu-rUoFaqDphA:45",
|
|
228
|
+
"headers" : {
|
|
229
|
+
"X-Opaque-Id" : "123456"
|
|
230
|
+
}
|
|
231
|
+
}
|
|
232
|
+
]
|
|
233
|
+
}
|
|
234
|
+
}
|
|
235
|
+
}
|
|
236
|
+
</code></pre>
|
|
237
|
+
<p>In this example, <code>X-Opaque-Id: 123456</code> is the ID as a part of the response header.
|
|
238
|
+
The <code>X-Opaque-Id</code> in the task <code>headers</code> is the ID for the task that was initiated by the REST request.
|
|
239
|
+
The <code>X-Opaque-Id</code> in the children <code>headers</code> is the child task of the task that was initiated by the REST request.</p>
|
|
240
|
+
|
|
206
241
|
|
|
207
242
|
`<https://www.elastic.co/guide/en/elasticsearch/reference/8.17/tasks.html>`_
|
|
208
243
|
|
|
@@ -53,22 +53,24 @@ class TextStructureClient(NamespacedClient):
|
|
|
53
53
|
timestamp_format: t.Optional[str] = None,
|
|
54
54
|
) -> ObjectApiResponse[t.Any]:
|
|
55
55
|
"""
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
56
|
+
.. raw:: html
|
|
57
|
+
|
|
58
|
+
<p>Find the structure of a text field.
|
|
59
|
+
Find the structure of a text field in an Elasticsearch index.</p>
|
|
60
|
+
<p>This API provides a starting point for extracting further information from log messages already ingested into Elasticsearch.
|
|
61
|
+
For example, if you have ingested data into a very simple index that has just <code>@timestamp</code> and message fields, you can use this API to see what common structure exists in the message field.</p>
|
|
62
|
+
<p>The response from the API contains:</p>
|
|
63
|
+
<ul>
|
|
64
|
+
<li>Sample messages.</li>
|
|
65
|
+
<li>Statistics that reveal the most common values for all fields detected within the text and basic numeric statistics for numeric fields.</li>
|
|
66
|
+
<li>Information about the structure of the text, which is useful when you write ingest configurations to index it or similarly formatted text.</li>
|
|
67
|
+
<li>Appropriate mappings for an Elasticsearch index, which you could use to ingest the text.</li>
|
|
68
|
+
</ul>
|
|
69
|
+
<p>All this information can be calculated by the structure finder with no guidance.
|
|
70
|
+
However, you can optionally override some of the decisions about the text structure by specifying one or more query parameters.</p>
|
|
71
|
+
<p>If the structure finder produces unexpected results, specify the <code>explain</code> query parameter and an explanation will appear in the response.
|
|
72
|
+
It helps determine why the returned structure was chosen.</p>
|
|
73
|
+
|
|
72
74
|
|
|
73
75
|
`<https://www.elastic.co/guide/en/elasticsearch/reference/8.17/find-field-structure.html>`_
|
|
74
76
|
|
|
@@ -237,23 +239,25 @@ class TextStructureClient(NamespacedClient):
|
|
|
237
239
|
body: t.Optional[t.Dict[str, t.Any]] = None,
|
|
238
240
|
) -> ObjectApiResponse[t.Any]:
|
|
239
241
|
"""
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
242
|
+
.. raw:: html
|
|
243
|
+
|
|
244
|
+
<p>Find the structure of text messages.
|
|
245
|
+
Find the structure of a list of text messages.
|
|
246
|
+
The messages must contain data that is suitable to be ingested into Elasticsearch.</p>
|
|
247
|
+
<p>This API provides a starting point for ingesting data into Elasticsearch in a format that is suitable for subsequent use with other Elastic Stack functionality.
|
|
248
|
+
Use this API rather than the find text structure API if your input text has already been split up into separate messages by some other process.</p>
|
|
249
|
+
<p>The response from the API contains:</p>
|
|
250
|
+
<ul>
|
|
251
|
+
<li>Sample messages.</li>
|
|
252
|
+
<li>Statistics that reveal the most common values for all fields detected within the text and basic numeric statistics for numeric fields.</li>
|
|
253
|
+
<li>Information about the structure of the text, which is useful when you write ingest configurations to index it or similarly formatted text.
|
|
254
|
+
Appropriate mappings for an Elasticsearch index, which you could use to ingest the text.</li>
|
|
255
|
+
</ul>
|
|
256
|
+
<p>All this information can be calculated by the structure finder with no guidance.
|
|
257
|
+
However, you can optionally override some of the decisions about the text structure by specifying one or more query parameters.</p>
|
|
258
|
+
<p>If the structure finder produces unexpected results, specify the <code>explain</code> query parameter and an explanation will appear in the response.
|
|
259
|
+
It helps determine why the returned structure was chosen.</p>
|
|
260
|
+
|
|
257
261
|
|
|
258
262
|
`<https://www.elastic.co/guide/en/elasticsearch/reference/8.17/find-message-structure.html>`_
|
|
259
263
|
|
|
@@ -410,22 +414,24 @@ class TextStructureClient(NamespacedClient):
|
|
|
410
414
|
timestamp_format: t.Optional[str] = None,
|
|
411
415
|
) -> ObjectApiResponse[t.Any]:
|
|
412
416
|
"""
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
417
|
+
.. raw:: html
|
|
418
|
+
|
|
419
|
+
<p>Find the structure of a text file.
|
|
420
|
+
The text file must contain data that is suitable to be ingested into Elasticsearch.</p>
|
|
421
|
+
<p>This API provides a starting point for ingesting data into Elasticsearch in a format that is suitable for subsequent use with other Elastic Stack functionality.
|
|
422
|
+
Unlike other Elasticsearch endpoints, the data that is posted to this endpoint does not need to be UTF-8 encoded and in JSON format.
|
|
423
|
+
It must, however, be text; binary text formats are not currently supported.
|
|
424
|
+
The size is limited to the Elasticsearch HTTP receive buffer size, which defaults to 100 Mb.</p>
|
|
425
|
+
<p>The response from the API contains:</p>
|
|
426
|
+
<ul>
|
|
427
|
+
<li>A couple of messages from the beginning of the text.</li>
|
|
428
|
+
<li>Statistics that reveal the most common values for all fields detected within the text and basic numeric statistics for numeric fields.</li>
|
|
429
|
+
<li>Information about the structure of the text, which is useful when you write ingest configurations to index it or similarly formatted text.</li>
|
|
430
|
+
<li>Appropriate mappings for an Elasticsearch index, which you could use to ingest the text.</li>
|
|
431
|
+
</ul>
|
|
432
|
+
<p>All this information can be calculated by the structure finder with no guidance.
|
|
433
|
+
However, you can optionally override some of the decisions about the text structure by specifying one or more query parameters.</p>
|
|
434
|
+
|
|
429
435
|
|
|
430
436
|
`<https://www.elastic.co/guide/en/elasticsearch/reference/8.17/find-structure.html>`_
|
|
431
437
|
|
|
@@ -607,9 +613,12 @@ class TextStructureClient(NamespacedClient):
|
|
|
607
613
|
body: t.Optional[t.Dict[str, t.Any]] = None,
|
|
608
614
|
) -> ObjectApiResponse[t.Any]:
|
|
609
615
|
"""
|
|
610
|
-
|
|
611
|
-
|
|
612
|
-
|
|
616
|
+
.. raw:: html
|
|
617
|
+
|
|
618
|
+
<p>Test a Grok pattern.
|
|
619
|
+
Test a Grok pattern on one or more lines of text.
|
|
620
|
+
The API indicates whether the lines match the pattern together with the offsets and lengths of the matched substrings.</p>
|
|
621
|
+
|
|
613
622
|
|
|
614
623
|
`<https://www.elastic.co/guide/en/elasticsearch/reference/8.17/test-grok-pattern.html>`_
|
|
615
624
|
|