Skip to content

[Drivers] Note about Adaptive Rate Limiting#155

Merged
rachel-mack merged 6 commits into10gen:mainfrom
rachel-mack:DOCSP-58635-IVM-adaptive-rate-limiting
Apr 10, 2026
Merged

[Drivers] Note about Adaptive Rate Limiting#155
rachel-mack merged 6 commits into10gen:mainfrom
rachel-mack:DOCSP-58635-IVM-adaptive-rate-limiting

Conversation

@rachel-mack
Copy link
Copy Markdown
Collaborator

JIRA: https://jira.mongodb.org/browse/DOCSP-58635

Purpose: This note will be added to drivers that support the progressive back-off workflow.

@rachel-mack rachel-mack requested a review from Copilot March 24, 2026 17:34
@rachel-mack rachel-mack review requested due to automatic review settings March 24, 2026 17:36
@@ -0,0 +1,13 @@
.. note::

You may find errors with ``SystemOverloadedError`` or ``RetryableError`` in
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

An important thing to note here is that even with newer drivers, users can/will still see these errors if the overload is sustained and strong enough. This will happen when a driver exhausts its retry count for a given request or, in the future pending design finalization, when the driver's retry budget/token bucket is emptied. They will see a lot fewer of these errors, and in the cases of transient or minor overload, they won't see them at all.

So while this guidance to upgrade is certainly still true and recommended, users of newer drivers should still be encouraged to make an informed decision on their end in response to overload (e.g. alerting their systems, inducing their own queueing/throttling, etc).

For the purposes of this PR, I think we can reword this slightly to still encourage upgrade without implying the errors are purely an old-driver problem, and separately we come up with further guidance on how all users can handle these errors that may end up here or in the Atlas docs. We're having discussions with product on this currently.

@@ -0,0 +1,14 @@
.. note::

If you find errors with ``SystemOverloadedError`` or ``RetryableError``
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This language reads a bit vague to me: users will start getting application failures due to these errors, they won't just log errors and continue running.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We need to clearly communicate to users that these errors WILL cause application failures when they occur without either code changes to explicitly ignore them or upgrading their driver to a backpressure-supported release.

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@NoahStapp could you take a look at my most recent changes?

@rachel-mack rachel-mack requested a review from NoahStapp March 30, 2026 20:28
Comment on lines +3 to +9
If errors with ``SystemOverloadedError`` or ``RetryableError``
labels are causing application failures, or appearing in your application
logs, you can consider changes to your retry settings. One option is to
enable adaptive rate limiting. Adaptive rate limiting helps
manage server load by dynamically adjusting request rates based on current
conditions, while also managing client-side retry requests to mitigate
errors. This feature is available on MongoDB 8.3 and supported by the
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The cause and effect are a little backward here. Adaptive rate limiting is one of the few features that can cause SystemOverloadedErrors to be returned.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah I think the old phrasing of this text was closer to what we want here, with the modifications I suggested before.

Comment on lines +3 to +9
If errors with ``SystemOverloadedError`` or ``RetryableError``
labels are causing application failures, or appearing in your application
logs, you can consider changes to your retry settings. One option is to
enable adaptive rate limiting. Adaptive rate limiting helps
manage server load by dynamically adjusting request rates based on current
conditions, while also managing client-side retry requests to mitigate
errors. This feature is available on MongoDB 8.3 and supported by the
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah I think the old phrasing of this text was closer to what we want here, with the modifications I suggested before.

@rachel-mack rachel-mack requested a review from NoahStapp April 9, 2026 14:36
driver may not be upgraded to a version that supports adaptive rate limiting.
We recommend upgrading your |driver-name| to version |ivm-compatible-version|
or later. If you continue to see these errors after upgrading, you may need
to review your Intelligent Workload Management (IWM) configuration.
Copy link
Copy Markdown

@NoahStapp NoahStapp Apr 9, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As Patrick mentioned in one of his earlier comments, users may also address continued errors through code or system changes on the application side (custom error handling, client-side request throttling, etc), independent of IWM configuration on their cluster. It's possible that the specific situation causing their overload requires (or prefers) these application changes rather than being solvable through server-side configuration.

@rachel-mack rachel-mack requested a review from NoahStapp April 10, 2026 16:17
@rachel-mack rachel-mack merged commit ca1bf66 into 10gen:main Apr 10, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants