elasticsearch 8.11.1__tar.gz → 8.12.0__tar.gz
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-8.11.1 → elasticsearch-8.12.0}/CONTRIBUTING.md +1 -1
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/PKG-INFO +2 -3
- elasticsearch-8.12.0/docs/sphinx/api/esql.rst +9 -0
- elasticsearch-8.12.0/docs/sphinx/api/inference.rst +9 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/docs/sphinx/api.rst +3 -1
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/docs/sphinx/async.rst +9 -14
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/docs/sphinx/index.rst +14 -11
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/docs/sphinx/quickstart.rst +4 -2
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_async/client/__init__.py +493 -347
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_async/client/async_search.py +108 -72
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_async/client/autoscaling.py +13 -8
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_async/client/cat.py +26 -26
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_async/client/ccr.py +178 -117
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_async/client/cluster.py +56 -48
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_async/client/dangling_indices.py +3 -3
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_async/client/enrich.py +15 -13
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_async/client/eql.py +53 -36
- elasticsearch-8.12.0/elasticsearch/_async/client/esql.py +99 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_async/client/features.py +2 -2
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_async/client/fleet.py +111 -71
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_async/client/graph.py +13 -11
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_async/client/ilm.py +33 -27
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_async/client/indices.py +326 -227
- elasticsearch-8.12.0/elasticsearch/_async/client/inference.py +212 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_async/client/ingest.py +28 -24
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_async/client/license.py +15 -13
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_async/client/logstash.py +13 -10
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_async/client/migration.py +3 -3
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_async/client/ml.py +758 -538
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_async/client/monitoring.py +10 -5
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_async/client/nodes.py +13 -11
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_async/client/query_ruleset.py +12 -10
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_async/client/rollup.py +59 -46
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_async/client/search_application.py +23 -16
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_async/client/searchable_snapshots.py +23 -16
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_async/client/security.py +391 -289
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_async/client/shutdown.py +18 -14
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_async/client/slm.py +23 -21
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_async/client/snapshot.py +91 -65
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_async/client/sql.py +81 -58
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_async/client/ssl.py +1 -1
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_async/client/synonyms.py +23 -19
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_async/client/tasks.py +3 -3
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_async/client/text_structure.py +10 -5
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_async/client/transform.py +111 -75
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_async/client/watcher.py +77 -55
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_async/client/xpack.py +2 -2
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_async/helpers.py +1 -1
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_sync/client/__init__.py +493 -347
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_sync/client/async_search.py +108 -72
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_sync/client/autoscaling.py +13 -8
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_sync/client/cat.py +26 -26
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_sync/client/ccr.py +178 -117
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_sync/client/cluster.py +56 -48
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_sync/client/dangling_indices.py +3 -3
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_sync/client/enrich.py +15 -13
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_sync/client/eql.py +53 -36
- elasticsearch-8.12.0/elasticsearch/_sync/client/esql.py +99 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_sync/client/features.py +2 -2
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_sync/client/fleet.py +111 -71
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_sync/client/graph.py +13 -11
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_sync/client/ilm.py +33 -27
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_sync/client/indices.py +326 -227
- elasticsearch-8.12.0/elasticsearch/_sync/client/inference.py +212 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_sync/client/ingest.py +28 -24
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_sync/client/license.py +15 -13
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_sync/client/logstash.py +13 -10
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_sync/client/migration.py +3 -3
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_sync/client/ml.py +758 -538
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_sync/client/monitoring.py +10 -5
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_sync/client/nodes.py +13 -11
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_sync/client/query_ruleset.py +12 -10
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_sync/client/rollup.py +59 -46
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_sync/client/search_application.py +23 -16
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_sync/client/searchable_snapshots.py +23 -16
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_sync/client/security.py +391 -289
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_sync/client/shutdown.py +18 -14
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_sync/client/slm.py +23 -21
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_sync/client/snapshot.py +91 -65
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_sync/client/sql.py +81 -58
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_sync/client/ssl.py +1 -1
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_sync/client/synonyms.py +23 -19
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_sync/client/tasks.py +3 -3
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_sync/client/text_structure.py +10 -5
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_sync/client/transform.py +111 -75
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_sync/client/utils.py +34 -10
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_sync/client/watcher.py +77 -55
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_sync/client/xpack.py +2 -2
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_version.py +1 -1
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/client.py +2 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/helpers/actions.py +1 -1
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch.egg-info/PKG-INFO +2 -3
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch.egg-info/SOURCES.txt +6 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/setup.py +1 -2
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/CHANGELOG.md +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/LICENSE +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/MANIFEST.in +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/NOTICE +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/README.rst +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/docs/sphinx/Makefile +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/docs/sphinx/api/autoscaling.rst +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/docs/sphinx/api/cat.rst +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/docs/sphinx/api/ccr.rst +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/docs/sphinx/api/cluster.rst +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/docs/sphinx/api/dangling-indices.rst +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/docs/sphinx/api/elasticsearch.rst +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/docs/sphinx/api/enrich-policies.rst +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/docs/sphinx/api/eql.rst +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/docs/sphinx/api/fleet.rst +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/docs/sphinx/api/graph-explore.rst +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/docs/sphinx/api/index-lifecycle-management.rst +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/docs/sphinx/api/indices.rst +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/docs/sphinx/api/ingest-pipelines.rst +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/docs/sphinx/api/license.rst +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/docs/sphinx/api/logstash.rst +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/docs/sphinx/api/migration.rst +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/docs/sphinx/api/ml.rst +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/docs/sphinx/api/monitoring.rst +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/docs/sphinx/api/nodes.rst +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/docs/sphinx/api/query-rules.rst +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/docs/sphinx/api/rollup-indices.rst +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/docs/sphinx/api/search-application.rst +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/docs/sphinx/api/searchable-snapshots.rst +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/docs/sphinx/api/security.rst +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/docs/sphinx/api/shutdown.rst +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/docs/sphinx/api/snapshot-lifecycle-management.rst +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/docs/sphinx/api/snapshots.rst +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/docs/sphinx/api/snapshottable-features.rst +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/docs/sphinx/api/sql.rst +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/docs/sphinx/api/synonyms.rst +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/docs/sphinx/api/tasks.rst +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/docs/sphinx/api/text-structure.rst +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/docs/sphinx/api/tls-ssl.rst +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/docs/sphinx/api/transforms.rst +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/docs/sphinx/api/watcher.rst +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/docs/sphinx/api/x-pack.rst +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/docs/sphinx/conf.py +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/docs/sphinx/exceptions.rst +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/docs/sphinx/helpers.rst +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/docs/sphinx/interactive.rst +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/__init__.py +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_async/__init__.py +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_async/client/_base.py +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_async/client/utils.py +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_sync/__init__.py +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_sync/client/_base.py +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/_utils.py +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/compat.py +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/exceptions.py +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/helpers/__init__.py +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/helpers/errors.py +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/py.typed +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/serializer.py +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch/transport.py +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch.egg-info/dependency_links.txt +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch.egg-info/not-zip-safe +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch.egg-info/requires.txt +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/elasticsearch.egg-info/top_level.txt +0 -0
- {elasticsearch-8.11.1 → elasticsearch-8.12.0}/setup.cfg +0 -0
|
@@ -13,7 +13,7 @@ before writing too much code.
|
|
|
13
13
|
## Running Elasticsearch locally
|
|
14
14
|
|
|
15
15
|
We've provided a script to start an Elasticsearch cluster of a certain version
|
|
16
|
-
found at `.
|
|
16
|
+
found at `.buildkite/run-elasticsearch.sh`.
|
|
17
17
|
|
|
18
18
|
There are several environment variables that control integration tests:
|
|
19
19
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: elasticsearch
|
|
3
|
-
Version: 8.
|
|
3
|
+
Version: 8.12.0
|
|
4
4
|
Summary: Python client for Elasticsearch
|
|
5
5
|
Home-page: https://github.com/elastic/elasticsearch-py
|
|
6
6
|
Author: Elastic Client Library Maintainers
|
|
@@ -15,7 +15,6 @@ Classifier: Intended Audience :: Developers
|
|
|
15
15
|
Classifier: Operating System :: OS Independent
|
|
16
16
|
Classifier: Programming Language :: Python
|
|
17
17
|
Classifier: Programming Language :: Python :: 3
|
|
18
|
-
Classifier: Programming Language :: Python :: 3.6
|
|
19
18
|
Classifier: Programming Language :: Python :: 3.7
|
|
20
19
|
Classifier: Programming Language :: Python :: 3.8
|
|
21
20
|
Classifier: Programming Language :: Python :: 3.9
|
|
@@ -24,7 +23,7 @@ Classifier: Programming Language :: Python :: 3.11
|
|
|
24
23
|
Classifier: Programming Language :: Python :: 3.12
|
|
25
24
|
Classifier: Programming Language :: Python :: Implementation :: CPython
|
|
26
25
|
Classifier: Programming Language :: Python :: Implementation :: PyPy
|
|
27
|
-
Requires-Python: >=3.
|
|
26
|
+
Requires-Python: >=3.7
|
|
28
27
|
Description-Content-Type: text/x-rst
|
|
29
28
|
License-File: LICENSE
|
|
30
29
|
License-File: NOTICE
|
|
@@ -10,7 +10,7 @@ arguments are required for all calls.
|
|
|
10
10
|
.. note::
|
|
11
11
|
|
|
12
12
|
Some API parameters in Elasticsearch are reserved keywords in Python.
|
|
13
|
-
For example the ``from`` query parameter for pagination would be aliased as
|
|
13
|
+
For example the ``from`` query parameter for pagination would be aliased as
|
|
14
14
|
``from_``.
|
|
15
15
|
|
|
16
16
|
.. toctree::
|
|
@@ -24,10 +24,12 @@ arguments are required for all calls.
|
|
|
24
24
|
api/dangling-indices
|
|
25
25
|
api/enrich-policies
|
|
26
26
|
api/eql
|
|
27
|
+
api/esql
|
|
27
28
|
api/fleet
|
|
28
29
|
api/graph-explore
|
|
29
30
|
api/index-lifecycle-management
|
|
30
31
|
api/indices
|
|
32
|
+
api/inference
|
|
31
33
|
api/ingest-pipelines
|
|
32
34
|
api/license
|
|
33
35
|
api/logstash
|
|
@@ -4,22 +4,17 @@ Using Asyncio with Elasticsearch
|
|
|
4
4
|
.. py:module:: elasticsearch
|
|
5
5
|
:no-index:
|
|
6
6
|
|
|
7
|
-
|
|
7
|
+
The ``elasticsearch`` package supports async/await with
|
|
8
8
|
`Asyncio <https://docs.python.org/3/library/asyncio.html>`_ and `Aiohttp <https://docs.aiohttp.org>`_.
|
|
9
9
|
You can either install ``aiohttp`` directly or use the ``[async]`` extra:
|
|
10
10
|
|
|
11
11
|
.. code-block:: bash
|
|
12
12
|
|
|
13
|
-
$ python -m pip install elasticsearch
|
|
13
|
+
$ python -m pip install elasticsearch aiohttp
|
|
14
14
|
|
|
15
15
|
# - OR -
|
|
16
16
|
|
|
17
|
-
$ python -m pip install elasticsearch[async]
|
|
18
|
-
|
|
19
|
-
.. note::
|
|
20
|
-
Async functionality is a new feature of this library in v7.8.0+ so
|
|
21
|
-
`please open an issue <https://github.com/elastic/elasticsearch-py/issues>`_
|
|
22
|
-
if you find an issue or have a question about async support.
|
|
17
|
+
$ python -m pip install elasticsearch[async]
|
|
23
18
|
|
|
24
19
|
Getting Started with Async
|
|
25
20
|
--------------------------
|
|
@@ -67,13 +62,13 @@ in the ``examples/fastapi-apm`` directory.
|
|
|
67
62
|
Frequently Asked Questions
|
|
68
63
|
--------------------------
|
|
69
64
|
|
|
70
|
-
|
|
71
|
-
|
|
65
|
+
ValueError when initializing ``AsyncElasticsearch``?
|
|
66
|
+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
|
72
67
|
|
|
73
|
-
If when trying to use ``AsyncElasticsearch``
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
68
|
+
If when trying to use ``AsyncElasticsearch`` you receive ``ValueError: You must
|
|
69
|
+
have 'aiohttp' installed to use AiohttpHttpNode`` you should ensure that you
|
|
70
|
+
have ``aiohttp`` installed in your environment (check with ``$ python -m pip
|
|
71
|
+
freeze | grep aiohttp``). Otherwise, async support won't be available.
|
|
77
72
|
|
|
78
73
|
What about the ``elasticsearch-async`` package?
|
|
79
74
|
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
|
@@ -38,8 +38,8 @@ Language clients are forward compatible; meaning that clients support communicat
|
|
|
38
38
|
with greater or equal minor versions of Elasticsearch. Elasticsearch language clients
|
|
39
39
|
are only backwards compatible with default distributions and without guarantees made.
|
|
40
40
|
|
|
41
|
-
If you
|
|
42
|
-
|
|
41
|
+
If you need multiple versions installed at the same time, versions are
|
|
42
|
+
also released, such as ``elasticsearch7`` and ``elasticsearch8``.
|
|
43
43
|
|
|
44
44
|
|
|
45
45
|
Example Usage
|
|
@@ -49,25 +49,28 @@ Example Usage
|
|
|
49
49
|
|
|
50
50
|
from datetime import datetime
|
|
51
51
|
from elasticsearch import Elasticsearch
|
|
52
|
-
|
|
52
|
+
|
|
53
|
+
es = Elasticsearch("http://localhost:9200")
|
|
53
54
|
|
|
54
55
|
doc = {
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
56
|
+
"author": "kimchy",
|
|
57
|
+
"text": "Elasticsearch: cool. bonsai cool.",
|
|
58
|
+
"timestamp": datetime.now(),
|
|
58
59
|
}
|
|
59
60
|
resp = es.index(index="test-index", id=1, document=doc)
|
|
60
|
-
print(resp[
|
|
61
|
+
print(resp["result"])
|
|
61
62
|
|
|
62
63
|
resp = es.get(index="test-index", id=1)
|
|
63
|
-
print(resp[
|
|
64
|
+
print(resp["_source"])
|
|
64
65
|
|
|
65
66
|
es.indices.refresh(index="test-index")
|
|
66
67
|
|
|
67
68
|
resp = es.search(index="test-index", query={"match_all": {}})
|
|
68
|
-
print("Got
|
|
69
|
-
for hit in resp[
|
|
70
|
-
print("
|
|
69
|
+
print("Got {} hits:".format(resp["hits"]["total"]["value"]))
|
|
70
|
+
for hit in resp["hits"]["hits"]:
|
|
71
|
+
print("{timestamp} {author} {text}".format(**hit["_source"]))
|
|
72
|
+
|
|
73
|
+
See more examples in the :ref:`quickstart` page.
|
|
71
74
|
|
|
72
75
|
|
|
73
76
|
|
|
@@ -1,4 +1,6 @@
|
|
|
1
|
-
|
|
1
|
+
.. _quickstart:
|
|
2
|
+
|
|
3
|
+
Quickstart
|
|
2
4
|
==========
|
|
3
5
|
|
|
4
6
|
This guide shows you how to install the Elasticsearch Python client and perform basic
|
|
@@ -7,7 +9,7 @@ operations like indexing or searching documents.
|
|
|
7
9
|
Requirements
|
|
8
10
|
------------
|
|
9
11
|
|
|
10
|
-
- `Python <https://www.python.org/>`_ 3.
|
|
12
|
+
- `Python <https://www.python.org/>`_ 3.7 or newer
|
|
11
13
|
- `pip <https://pip.pypa.io/en/stable/>`_
|
|
12
14
|
|
|
13
15
|
|