Skip to content

Commit c5f91fa

Browse files
committed
Added docs for request_timeout
1 parent c112399 commit c5f91fa

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

docs/api.rst

+7
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,13 @@ them::
2626
# ignore 404 and 400
2727
es.indices.delete(index='test-index', ignore=[400, 404])
2828

29+
You can also specify ``request_timeout`` (float) as part of any API call, this
30+
value will get passed to the ``perform_request`` method of the connection
31+
class::
32+
33+
# only wait for 1 second, regardless of the client's default
34+
es.cluster.health(wait_for_status='yellow', request_timeout=1)
35+
2936
.. note::
3037

3138
for compatibility with the Python ecosystem we use ``from_`` instead of

0 commit comments

Comments
 (0)