Skip to content

Commit

Permalink
Update APIs for Elasticsearch 7.12
Browse files Browse the repository at this point in the history
  • Loading branch information
sethmlarson committed Feb 24, 2021
1 parent bedf11d commit 9ceb756
Show file tree
Hide file tree
Showing 72 changed files with 1,148 additions and 699 deletions.
9 changes: 9 additions & 0 deletions docs/sphinx/xpack.rst
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,15 @@ can be used to manage your licences.
.. autoclass:: LicenseClient
:members:

Logstash
--------

`Logstash APIs <https://www.elastic.co/guide/en/elasticsearch/reference/7.x/logstash-apis.html>`_
manage Pipelines used by Logstash Central Management.

.. autoclass:: LogstashClient
:members:

Machine Learning
----------------

Expand Down
80 changes: 40 additions & 40 deletions elasticsearch/_async/client/__init__.py

Large diffs are not rendered by default.

8 changes: 4 additions & 4 deletions elasticsearch/_async/client/async_search.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ async def delete(self, id, params=None, headers=None):
Deletes an async search by ID. If the search is still running, the search
request will be cancelled. Otherwise, the saved search results are deleted.
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.x/async-search.html>`_
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.12/async-search.html>`_
:arg id: The async search ID
"""
Expand All @@ -42,7 +42,7 @@ async def get(self, id, params=None, headers=None):
Retrieves the results of a previously submitted async search request given its
ID.
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.x/async-search.html>`_
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.12/async-search.html>`_
:arg id: The async search ID
:arg keep_alive: Specify the time interval in which the results
Expand Down Expand Up @@ -106,7 +106,7 @@ async def submit(self, body=None, index=None, params=None, headers=None):
"""
Executes a search request asynchronously.
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.x/async-search.html>`_
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.12/async-search.html>`_
:arg body: The search definition using the Query DSL
:arg index: A comma-separated list of index names to search; use
Expand Down Expand Up @@ -212,7 +212,7 @@ async def status(self, id, params=None, headers=None):
Retrieves the status of a previously submitted async search request given its
ID.
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.x/async-search.html>`_
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.12/async-search.html>`_
:arg id: The async search ID
"""
Expand Down
8 changes: 4 additions & 4 deletions elasticsearch/_async/client/autoscaling.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ async def delete_autoscaling_policy(self, name, params=None, headers=None):
Deletes an autoscaling policy. Designed for indirect use by ECE/ESS and ECK.
Direct use is not supported.
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.x/autoscaling-delete-autoscaling-policy.html>`_
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.12/autoscaling-delete-autoscaling-policy.html>`_
:arg name: the name of the autoscaling policy
"""
Expand All @@ -45,7 +45,7 @@ async def get_autoscaling_policy(self, name, params=None, headers=None):
Retrieves an autoscaling policy. Designed for indirect use by ECE/ESS and ECK.
Direct use is not supported.
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.x/autoscaling-get-autoscaling-policy.html>`_
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.12/autoscaling-get-autoscaling-policy.html>`_
:arg name: the name of the autoscaling policy
"""
Expand All @@ -65,7 +65,7 @@ async def put_autoscaling_policy(self, name, body, params=None, headers=None):
Creates a new autoscaling policy. Designed for indirect use by ECE/ESS and ECK.
Direct use is not supported.
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.x/autoscaling-put-autoscaling-policy.html>`_
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.12/autoscaling-put-autoscaling-policy.html>`_
:arg name: the name of the autoscaling policy
:arg body: the specification of the autoscaling policy
Expand All @@ -89,7 +89,7 @@ async def get_autoscaling_capacity(self, params=None, headers=None):
policy. Designed for indirect use by ECE/ESS and ECK. Direct use is not
supported.
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.x/autoscaling-get-autoscaling-capacity.html>`_
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.12/autoscaling-get-autoscaling-capacity.html>`_
"""
return await self.transport.perform_request(
"GET", "/_autoscaling/capacity", params=params, headers=headers
Expand Down
50 changes: 25 additions & 25 deletions elasticsearch/_async/client/cat.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ async def aliases(self, name=None, params=None, headers=None):
Shows information about currently configured aliases to indices including
filter and routing infos.
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.x/cat-alias.html>`_
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.12/cat-alias.html>`_
:arg name: A comma-separated list of alias names to return
:arg expand_wildcards: Whether to expand wildcard expression to
Expand All @@ -51,7 +51,7 @@ async def allocation(self, node_id=None, params=None, headers=None):
Provides a snapshot of how many shards are allocated to each data node and how
much disk space they are using.
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.x/cat-allocation.html>`_
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.12/cat-allocation.html>`_
:arg node_id: A comma-separated list of node IDs or names to
limit the returned information
Expand Down Expand Up @@ -82,7 +82,7 @@ async def count(self, index=None, params=None, headers=None):
Provides quick access to the document count of the entire cluster, or
individual indices.
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.x/cat-count.html>`_
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.12/cat-count.html>`_
:arg index: A comma-separated list of index names to limit the
returned information
Expand All @@ -103,7 +103,7 @@ async def health(self, params=None, headers=None):
"""
Returns a concise representation of the cluster health.
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.x/cat-health.html>`_
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.12/cat-health.html>`_
:arg format: a short version of the Accept header, e.g. json,
yaml
Expand All @@ -125,7 +125,7 @@ async def help(self, params=None, headers=None):
"""
Returns help for the Cat APIs.
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.x/cat.html>`_
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.12/cat.html>`_
:arg help: Return help information
:arg s: Comma-separated list of column names or column aliases
Expand Down Expand Up @@ -155,7 +155,7 @@ async def indices(self, index=None, params=None, headers=None):
Returns information about indices: number of primaries and replicas, document
counts, disk size, ...
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.x/cat-indices.html>`_
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.12/cat-indices.html>`_
:arg index: A comma-separated list of index names to limit the
returned information
Expand Down Expand Up @@ -194,7 +194,7 @@ async def master(self, params=None, headers=None):
"""
Returns information about the master node.
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.x/cat-master.html>`_
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.12/cat-master.html>`_
:arg format: a short version of the Accept header, e.g. json,
yaml
Expand Down Expand Up @@ -228,7 +228,7 @@ async def nodes(self, params=None, headers=None):
"""
Returns basic statistics about performance of cluster nodes.
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.x/cat-nodes.html>`_
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.12/cat-nodes.html>`_
:arg bytes: The unit in which to display byte values Valid
choices: b, k, kb, m, mb, g, gb, t, tb, p, pb
Expand Down Expand Up @@ -259,7 +259,7 @@ async def recovery(self, index=None, params=None, headers=None):
"""
Returns information about index shard recoveries, both on-going completed.
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.x/cat-recovery.html>`_
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.12/cat-recovery.html>`_
:arg index: Comma-separated list or wildcard expression of index
names to limit the returned information
Expand Down Expand Up @@ -290,7 +290,7 @@ async def shards(self, index=None, params=None, headers=None):
"""
Provides a detailed view of shard allocation on nodes.
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.x/cat-shards.html>`_
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.12/cat-shards.html>`_
:arg index: A comma-separated list of index names to limit the
returned information
Expand Down Expand Up @@ -319,7 +319,7 @@ async def segments(self, index=None, params=None, headers=None):
"""
Provides low-level information about the segments in the shards of an index.
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.x/cat-segments.html>`_
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.12/cat-segments.html>`_
:arg index: A comma-separated list of index names to limit the
returned information
Expand All @@ -342,7 +342,7 @@ async def pending_tasks(self, params=None, headers=None):
"""
Returns a concise representation of the cluster pending tasks.
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.x/cat-pending-tasks.html>`_
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.12/cat-pending-tasks.html>`_
:arg format: a short version of the Accept header, e.g. json,
yaml
Expand All @@ -368,7 +368,7 @@ async def thread_pool(self, thread_pool_patterns=None, params=None, headers=None
Returns cluster-wide thread pool statistics per node. By default the active,
queue and rejected statistics are returned for all thread pools.
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.x/cat-thread-pool.html>`_
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.12/cat-thread-pool.html>`_
:arg thread_pool_patterns: A comma-separated list of regular-
expressions to filter the thread pools in the output
Expand Down Expand Up @@ -399,7 +399,7 @@ async def fielddata(self, fields=None, params=None, headers=None):
Shows how much heap memory is currently being used by fielddata on every data
node in the cluster.
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.x/cat-fielddata.html>`_
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.12/cat-fielddata.html>`_
:arg fields: A comma-separated list of fields to return in the
output
Expand Down Expand Up @@ -427,7 +427,7 @@ async def plugins(self, params=None, headers=None):
"""
Returns information about installed plugins across nodes node.
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.x/cat-plugins.html>`_
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.12/cat-plugins.html>`_
:arg format: a short version of the Accept header, e.g. json,
yaml
Expand All @@ -452,7 +452,7 @@ async def nodeattrs(self, params=None, headers=None):
"""
Returns information about custom node attributes.
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.x/cat-nodeattrs.html>`_
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.12/cat-nodeattrs.html>`_
:arg format: a short version of the Accept header, e.g. json,
yaml
Expand All @@ -475,7 +475,7 @@ async def repositories(self, params=None, headers=None):
"""
Returns information about snapshot repositories registered in the cluster.
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.x/cat-repositories.html>`_
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.12/cat-repositories.html>`_
:arg format: a short version of the Accept header, e.g. json,
yaml
Expand All @@ -500,7 +500,7 @@ async def snapshots(self, repository=None, params=None, headers=None):
"""
Returns all snapshots in a specific repository.
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.x/cat-snapshots.html>`_
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.12/cat-snapshots.html>`_
:arg repository: Name of repository from which to fetch the
snapshot information
Expand Down Expand Up @@ -542,7 +542,7 @@ async def tasks(self, params=None, headers=None):
Returns information about the tasks currently executing on one or more nodes in
the cluster.
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.x/tasks.html>`_
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.12/tasks.html>`_
:arg actions: A comma-separated list of actions that should be
returned. Leave empty to return all.
Expand Down Expand Up @@ -571,7 +571,7 @@ async def templates(self, name=None, params=None, headers=None):
"""
Returns information about existing templates.
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.x/cat-templates.html>`_
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.12/cat-templates.html>`_
:arg name: A pattern that returned template names must match
:arg format: a short version of the Accept header, e.g. json,
Expand All @@ -595,7 +595,7 @@ async def ml_data_frame_analytics(self, id=None, params=None, headers=None):
"""
Gets configuration and usage information about data frame analytics jobs.
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.x/cat-dfanalytics.html>`_
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.12/cat-dfanalytics.html>`_
:arg id: The ID of the data frame analytics to fetch
:arg allow_no_match: Whether to ignore if a wildcard expression
Expand Down Expand Up @@ -627,7 +627,7 @@ async def ml_datafeeds(self, datafeed_id=None, params=None, headers=None):
"""
Gets configuration and usage information about datafeeds.
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.x/cat-datafeeds.html>`_
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.12/cat-datafeeds.html>`_
:arg datafeed_id: The ID of the datafeeds stats to fetch
:arg allow_no_datafeeds: Whether to ignore if a wildcard
Expand Down Expand Up @@ -668,7 +668,7 @@ async def ml_jobs(self, job_id=None, params=None, headers=None):
"""
Gets configuration and usage information about anomaly detection jobs.
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.x/cat-anomaly-detectors.html>`_
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.12/cat-anomaly-detectors.html>`_
:arg job_id: The ID of the jobs stats to fetch
:arg allow_no_jobs: Whether to ignore if a wildcard expression
Expand Down Expand Up @@ -712,7 +712,7 @@ async def ml_trained_models(self, model_id=None, params=None, headers=None):
"""
Gets configuration and usage information about inference trained models.
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.x/cat-trained-model.html>`_
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.12/cat-trained-model.html>`_
:arg model_id: The ID of the trained models stats to fetch
:arg allow_no_match: Whether to ignore if a wildcard expression
Expand Down Expand Up @@ -751,7 +751,7 @@ async def transforms(self, transform_id=None, params=None, headers=None):
"""
Gets configuration and usage information about transforms.
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.x/cat-transforms.html>`_
`<https://www.elastic.co/guide/en/elasticsearch/reference/7.12/cat-transforms.html>`_
:arg transform_id: The id of the transform for which to get
stats. '_all' or '*' implies all transforms
Expand Down
Loading

0 comments on commit 9ceb756

Please sign in to comment.