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

Reconsider how we apply overrides for Cost Model Coefficients

    • Type: Icon: Task Task
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 6.3.0-rc0
    • Affects Version/s: None
    • Component/s: None
    • Fully Compatible
    • QO 2022-11-14
    • 164

      We parse the BSON object for every query we should to do only when the overrides are changed.

      One possible solution it to use CostModelManager to cache overrides, every time the overrides are changed we can cache new coefficients in the CostModelManager object. We don't need to store coefficient for every overrides only for the last one since there is always just one active overrides object at any time.

      We always apply overrides to the default coefficients, so we can always reset to the defaults just by setting overrides to an empty object, which should be mentioned in the comments and in the docs.

            Assignee:
            ruoxin.xu@mongodb.com Ruoxin Xu
            Reporter:
            alexander.ignatyev@mongodb.com Alexander Ignatyev
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: