You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: pymongo/asynchronous/mongo_client.py
+6-8Lines changed: 6 additions & 8 deletions
Original file line number
Diff line number
Diff line change
@@ -615,17 +615,17 @@ def __init__(
615
615
client to use Stable API. See `versioned API <https://www.mongodb.com/docs/manual/reference/stable-api/#what-is-the-stable-api--and-should-you-use-it->`_ for
616
616
details.
617
617
618
-
| **Adaptive retry options:**
619
-
| (If not enabled explicitly, adaptive retries will not be enabled.)
618
+
| **Overload retry options:**|
620
619
621
-
- `adaptive_retries`: (boolean) Whether the adaptive retry mechanism is enabled for this client.
622
-
If enabled, server overload errors will use a token-bucket based system to mitigate further overload.
620
+
- `max_adaptive_retries`: (int) How many retries to allow for overload errors. Defaults to ``2``.
621
+
- `enable_overload_retargeting`: (boolean) Whether overload retargeting is enabled for this client.
622
+
If enabled, server overload errors will cause retry attempts to select a server that has not yet returned an overload error, if possible.
623
623
Defaults to ``False``.
624
624
625
625
.. seealso:: The MongoDB documentation on `connections <https://dochub.mongodb.org/core/connections>`_.
626
626
627
627
.. versionchanged:: 4.17
628
-
Added the ``adaptive_retries`` URI and keyword argument.
628
+
Added the ``max_adaptive_retries`` and ``enable_overload_retargeting`` URI and keyword arguments.
629
629
630
630
.. versionchanged:: 4.5
631
631
Added the ``serverMonitoringMode`` keyword argument.
Copy file name to clipboardExpand all lines: pymongo/synchronous/mongo_client.py
+6-8Lines changed: 6 additions & 8 deletions
Original file line number
Diff line number
Diff line change
@@ -615,17 +615,17 @@ def __init__(
615
615
client to use Stable API. See `versioned API <https://www.mongodb.com/docs/manual/reference/stable-api/#what-is-the-stable-api--and-should-you-use-it->`_ for
616
616
details.
617
617
618
-
| **Adaptive retry options:**
619
-
| (If not enabled explicitly, adaptive retries will not be enabled.)
618
+
| **Overload retry options:**|
620
619
621
-
- `adaptive_retries`: (boolean) Whether the adaptive retry mechanism is enabled for this client.
622
-
If enabled, server overload errors will use a token-bucket based system to mitigate further overload.
620
+
- `max_adaptive_retries`: (int) How many retries to allow for overload errors. Defaults to ``2``.
621
+
- `enable_overload_retargeting`: (boolean) Whether overload retargeting is enabled for this client.
622
+
If enabled, server overload errors will cause retry attempts to select a server that has not yet returned an overload error, if possible.
623
623
Defaults to ``False``.
624
624
625
625
.. seealso:: The MongoDB documentation on `connections <https://dochub.mongodb.org/core/connections>`_.
626
626
627
627
.. versionchanged:: 4.17
628
-
Added the ``adaptive_retries`` URI and keyword argument.
628
+
Added the ``max_adaptive_retries`` and ``enable_overload_retargeting`` URI and keyword arguments.
629
629
630
630
.. versionchanged:: 4.5
631
631
Added the ``serverMonitoringMode`` keyword argument.
0 commit comments