Multiplanning storms after a plan cache flush
Parent: Replanning loops and replanReason · Published reference · snapshot 2026-10-31
↓ Facts as markdownall context files
Source-anchored research for Multiplanning storms after a plan cache flush. Run status: COMPLETED.
These notes link each claim to its source. Some citations identify archived research reports that are no longer hosted on this site. A published reference means the content is available; it does not certify independent review or accuracy.Read the editorial policy and follow the sources before relying on a claim.
How it works
- Percona's planning walkthrough identifies candidate generation and trial execution as CPU-, memory-, and potentially disk-intensive. Together with the documented cache lifecycle, this supports measuring cold-cache planning separately from warmed execution when comparing index strategies. (medium confidence) [source]
How-to and procedures
- Use planning duration alongside evidence of actual candidate evaluation and total operation cost. MongoDB's profiler documentation warns that older planningTimeMicros measurements can include pre-retry work; SERVER-62150 also identifies planningTimeMicros and queryFramework as diagnostic signals. A large timing value alone does not prove a multiplanning storm. (medium confidence) [source]
Problems, failure modes and limitations
- Inference: concurrent arrivals during a cold-cache interval can amplify candidate-trial work and consume resources before a reusable entry becomes active. This risk follows from repeated evaluation in non-active states and MongoDB's explicit per-key multiplanning concurrency protection; it does not establish a universal outage threshold. (medium confidence) [source]
- Tencent's operational guidance warns that unrepresentative requests arriving after a flush can influence the subsequently cached choice. A cold-cache interval can therefore introduce plan-quality risk as well as planning overhead; repeated evaluation does not guarantee a better plan. (medium confidence) [source]
- The inspected MongoDB master header describes MultiPlanRateLimiter: after aggregate concurrent candidate trials exceed a threshold, per-key tickets limit candidate concurrency; waiting trials yield resources, and cache-entry activation wakes waiters. This is source-level evidence of a safeguard, not proof that any particular released deployment enables it. (low confidence) (verified as of 2026-10-30) [source]
Comparisons and alternatives
- SERVER-62150 records an SBE defect where planning could be proportional to the slowest candidate rather than the fastest, amplifying the cost of cache misses. The ticket says MongoDB 8.0 fixes this by using classic multiplanning even when SBE executes the winner; the defect must not be generalized to all later versions. (low confidence) (verified as of 2025-07-01) [source]
Facts and statements
- MongoDB documents Missing and Inactive cache states in which candidate plans are evaluated again; an Inactive placeholder is not a reusable plan. Consequently, a post-flush cache need not become reusable after just one execution. (medium confidence) [source]
- The 2024 First Past the Post paper experimentally evaluates MongoDB 7.0.1 candidate selection and reports suboptimal choices. It supplies independent evidence about trial-ranking limitations, but its abstract does not demonstrate concurrent post-flush overload or measure a storm. (low confidence) [source]
Children
- No children recorded.