Skip to content

Commit

Permalink
update api to main
Browse files Browse the repository at this point in the history
  • Loading branch information
miriam-eid committed Aug 2, 2022
1 parent 9e963d9 commit 2b6d2bc
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 4 deletions.
7 changes: 5 additions & 2 deletions elasticsearch/_async/client/snapshot.py
Original file line number Diff line number Diff line change
Expand Up @@ -414,6 +414,7 @@ async def get(
ignore_unavailable: t.Optional[bool] = None,
include_repository: t.Optional[bool] = None,
index_details: t.Optional[bool] = None,
index_names: t.Optional[bool] = None,
master_timeout: t.Optional[
t.Union["t.Literal[-1]", "t.Literal[0]", str]
] = None,
Expand Down Expand Up @@ -449,12 +450,12 @@ async def get(
index- or shard count.
:param ignore_unavailable: If false, the request returns an error for any snapshots
that are unavailable.
:param include_repository: Whether to include the repository name in the snapshot
info. Defaults to true.
:param include_repository: If true, returns the repository name in each snapshot.
:param index_details: If true, returns additional information about each index
in the snapshot comprising the number of shards in the index, the total size
of the index in bytes, and the maximum number of segments per shard in the
index. Defaults to false, meaning that this information is omitted.
:param index_names: If true, returns the name of each index in each snapshot.
:param master_timeout: Period to wait for a connection to the master node. If
no response is received before the timeout expires, the request fails and
returns an error.
Expand Down Expand Up @@ -498,6 +499,8 @@ async def get(
__query["include_repository"] = include_repository
if index_details is not None:
__query["index_details"] = index_details
if index_names is not None:
__query["index_names"] = index_names
if master_timeout is not None:
__query["master_timeout"] = master_timeout
if offset is not None:
Expand Down
7 changes: 5 additions & 2 deletions elasticsearch/_sync/client/snapshot.py
Original file line number Diff line number Diff line change
Expand Up @@ -414,6 +414,7 @@ def get(
ignore_unavailable: t.Optional[bool] = None,
include_repository: t.Optional[bool] = None,
index_details: t.Optional[bool] = None,
index_names: t.Optional[bool] = None,
master_timeout: t.Optional[
t.Union["t.Literal[-1]", "t.Literal[0]", str]
] = None,
Expand Down Expand Up @@ -449,12 +450,12 @@ def get(
index- or shard count.
:param ignore_unavailable: If false, the request returns an error for any snapshots
that are unavailable.
:param include_repository: Whether to include the repository name in the snapshot
info. Defaults to true.
:param include_repository: If true, returns the repository name in each snapshot.
:param index_details: If true, returns additional information about each index
in the snapshot comprising the number of shards in the index, the total size
of the index in bytes, and the maximum number of segments per shard in the
index. Defaults to false, meaning that this information is omitted.
:param index_names: If true, returns the name of each index in each snapshot.
:param master_timeout: Period to wait for a connection to the master node. If
no response is received before the timeout expires, the request fails and
returns an error.
Expand Down Expand Up @@ -498,6 +499,8 @@ def get(
__query["include_repository"] = include_repository
if index_details is not None:
__query["index_details"] = index_details
if index_names is not None:
__query["index_names"] = index_names
if master_timeout is not None:
__query["master_timeout"] = master_timeout
if offset is not None:
Expand Down

0 comments on commit 2b6d2bc

Please sign in to comment.