Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-98697

Avoid allocations when estimating equality prefix of index bounds

    • Type: Icon: Task Task
    • Resolution: Unresolved
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: None
    • Component/s: None
    • None
    • Query Optimization

      Currently when invoking the sampling estimator on index scan nodes, we pass the equality prefix of the bounds as a heuristic to account for the additional seeks that the cursor must perform. For example the bounds of [a: [1,1], b: [2, 5], c: [6,6]] are estimated as [a: [1,1], b: [2, 5], c: [MinKey,MaxKey]]. Our current approach creates a copy of the index bounds to do this as a convinence, but this is unnecessary.

      The task of this ticket is to avoid these allocations.

            Assignee:
            Unassigned Unassigned
            Reporter:
            ben.shteinfeld@mongodb.com Ben Shteinfeld
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated: