10000 Fix request_timeout example and doc · discord/kubernetes-client-python@8c4590b · GitHub
[go: up one dir, main page]

Skip to content

Commit 8c4590b

Browse files
committed
Fix request_timeout example and doc
Arg name should be _request_timeout. Single value type should be int or long. Signed-off-by: Hemslo Wang <hemslo.wang@gmail.com>
1 parent 90fc5d6 commit 8c4590b

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

examples/dynamic-client/request_timeout.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -51,15 +51,15 @@ def main():
5151
# Creating configmap `request-timeout-test-configmap` in the `default` namespace
5252
# Client-side timeout to 60 seconds
5353

54-
configmap = api.create(body=configmap_manifest, namespace="default", _request_time=60)
54+
configmap = api.create(body=configmap_manifest, namespace="default", _request_timeout=60)
5555

5656
print("\n[INFO] configmap `request-timeout-test-configmap` created\n")
5757

5858
# Listing the configmaps in the `default` namespace
5959
# Client-side timeout to 60 seconds
6060

6161
configmap_list = api.get(
62-
name=configmap_name, namespace="default", label_selector="foo=bar", _request_time=60
62+
name=configmap_name, namespace="default", label_selector="foo=bar", _request_timeout=60
6363
)
6464

6565
print("NAME:\n%s\n" % (configmap_list.metadata.name))

examples/watch/timeout-settings.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ There are two inputs available in the client, that could be used to set connecti
5050
- The value of the argument `_request_timeout`, **n** (which is time duration in seconds) is set to the socket used for the connection.
5151

5252
- In case, if the `_request_timeout` value is set, this argument can accept 2 types of input values ~
53-
- float,
53+
- int/long
5454
- a tuple (with a length of 2)
5555

5656
***Refer***

0 commit comments

Comments
 (0)
0