Reduce overhead of cursor caching

XMLWordPrintableJSON

    • Type: Improvement
    • Resolution: Unresolved
    • Priority: Major - P3
    • None
    • Affects Version/s: None
    • Component/s: Configuration
    • Storage Engines, Storage Engines - Foundations
    • Megabat - 2024-05-14, SE Foundations - 2025-06-06
    • 3

      We tried to remove the MongoDB cursor caching layer in SERVER-82970, but we found regressions caused by extra overhead in the WiredTiger cursor caching layer.

      The main sources of overhead seem to come from two places:

      • Config string parsing
      • Having to close and re-open the actual dhandle. In the MongoDB layer, we just call reset() when caching a cursor, which does not appear to incur the same overhead.

      In the mixed_multi_deletes_batched workload, this is the time spent constructing a WiredTigerCursor:

      • Before: 3.0%
      • After: 6.6%

      And this is zoomed into the unindex path:
      Before:

      After:

            Assignee:
            Donald Anderson
            Reporter:
            Louis Williams
            Votes:
            0 Vote for this issue
            Watchers:
            13 Start watching this issue

              Created:
              Updated: