Uploaded image for project: 'Documentation'
  1. Documentation
  2. DOCS-12651

Clarify triggering events for the query replanning mechanism

      Description

      The plan cache replanning mechanism can get triggered as outlined in this comment from SERVER-21064:

      This is fixed by SERVER-15225, which eliminated the notion of a cached "backup plan" and replaced it with the notion of "replanning". When this scenario occurs on a version where replanning is enabled by default (3.0.7 and higher), the cached plan hitting the 32 MB limit will cause us to restart plan selection from the beginning. We generate and rank several candidate plans, and correctly select the non-blocking plan as the winner.

      Presently the Query Plans page contains the following:

      If a matching entry exists, the query planner generates a plan based on that entry and evaluates its performance through a replanning mechanism. This mechanism makes a pass/fail decision based on the plan performance

      Usage of the word "performance" here may be too ambiguous. It is unclear if a failed execution (resulting from exceeding the sort threshold using the cached plan) would be considered simply an evaluation of its performance. More details about the events that trigger the replanning mechanism could help reduce confusion about replanned:1 entries in the log file.

      Scope of changes

      Impact to Other Docs

      MVP (Work and Date)

      Resources (Scope or Design Docs, Invision, etc.)

            Assignee:
            joseph.dougherty@mongodb.com Joseph Dougherty
            Reporter:
            christopher.harris@mongodb.com Chris Harris
            Votes:
            0 Vote for this issue
            Watchers:
            7 Start watching this issue

              Created:
              Updated:
              Resolved:
              46 weeks ago