Dynamic throttling thresholds for Exchange Online EWS/REST connections per mailbox
0 reputation · 21 Nov 2023, 21:58 UTC
0 reputation · 21 Nov 2023, 21:58 UTC
Goal: Determine what factors cause the Exchange Online EWS/REST connection limit per mailbox to shift from the documented soft limit of ~27‑30 concurrent connections under varying tenant load.
Context: Microsoft publishes a soft limit and returns HTTP 429 with Retry‑After when exceeded, but the internal algorithm that adjusts this limit dynamically based on overall tenant usage is not disclosed. This creates uncertainty for applications that rely on connection pooling and may experience intermittent pool exhaustion even when observed concurrency stays below the published threshold.
Uncertainty: Without visibility into the tenant‑wide signals (e.g., overall mailbox activity, service health, or licensing tier) that trigger the adjustment, it is unclear how to predict or monitor when the effective limit will be lower than the published value.
Questions:
33275 reputation · 21 Nov 2023, 23:40 UTC
The per‑mailbox soft limit of ~27‑30 concurrent EWS/REST connections is not fixed; Microsoft dynamically adjusts this threshold based on tenant‑wide conditions. When the effective limit drops below the published value, clients receive HTTP 429 with a Retry‑After header and an error category of Throttling (MailboxThrottled or ConnectionThrottled).
Get-ThrottlingPolicy shows the default policy but does not expose per‑mailbox editable limits without creating a custom policy.The adjustment appears to be driven by aggregate signals that reflect overall service pressure:
These factors are not exposed via admin APIs, which is why the exact formula remains undisclosed.
Retry‑After value and the exact ErrorCategory (MailboxThrottled vs ConnectionThrottled).Get-MailboxStatistics (look for large ItemCount or recent high‑volume operations) to see if the mailbox itself is a contributing factor.To refine the recommendation, please confirm the Retry‑After you are observing in the 429 responses (e.g., 30 seconds, 2 minutes). This value indicates whether the throttling is a short‑lived burst‑control action or a longer‑cooldown caused by a tenant‑wide limit adjustment.
Use comments to ask for clarification. Post a solution as an answer.
33,275 reputation · 21 Nov 2023, 23:03 UTC
When applications encounter HTTP 429 errors before reaching the 27-30 connection soft limit, it usually indicates that the tenant-wide service pressure signal is active. While the soft limit is a baseline, the effective ceiling is often compressed by aggregate factors like high global request volume or specific service health degradations.
To distinguish between dynamic throttling and soft-limit exhaustion, focus on the Retry-After header duration. If the duration varies significantly despite stable concurrency, the internal algorithm is likely adjusting the per-mailbox budget due to tenant-level load or mailbox-specific burst patterns. Monitoring the ErrorCategory in the response body can also help identify if the throttle is triggered by specific connection limits or broader mailbox-level policies.