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

Make CollectionPtr instances fetched directly from the CollectionCatalog invariant if any yield()/restore() is attempted

    • Type: Icon: Improvement Improvement
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 7.0.0-rc0
    • Affects Version/s: None
    • Component/s: None
    • Labels:
    • Storage Execution
    • Fully Compatible
    • Execution Team 2022-02-21, Execution Team 2023-02-20, Execution Team 2023-02-06

      Any code directly accessing a CollectionPtr through the CollectionCatalog interface should not have yield/restore capability. Only AutoGet* helpers should have CollectionPtr instances that yield. This ensures that the CollectionPtr is properly set up for the use case.

      Places like this CollectionCatalog function should return a default lambda that just invariants. The AutoGet helpers should always explicitly set the restoreFromYieldFn.

            Assignee:
            henrik.edin@mongodb.com Henrik Edin
            Reporter:
            dianna.hohensee@mongodb.com Dianna Hohensee (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

              Created:
              Updated:
              Resolved: