Remove preallocateSnapshotForOplogRead()

XMLWordPrintableJSON

    • Type: Improvement
    • Resolution: Fixed
    • Priority: Major - P3
    • 7.1.0-rc0
    • Affects Version/s: None
    • Component/s: None
    • None
    • Fully Compatible
    • Execution Team 2023-06-12, Execution EMEA Team 2023-06-26, Execution EMEA Team 2023-07-10
    • None
    • 3
    • None
    • None
    • None
    • None
    • None
    • None

      Currently we need to preallocate a snapshot differently if we are reading from the oplog or not.

      When we call preallocateSnapshotForOplogRead() we set the _isOplogReader flag in the WiredTigerRecoveryUnit, which is used when opening a snapshot and then when getting the oplog visibility TS (which is called from here, only when reading from the oplog).

      We should remove this logic and always assume we could be reading from the oplog. For that we'd just need to always set _oplogVisibleTs (when ReadSource is kNoTimestamp), that cost would be an atomic word read.

            Assignee:
            Daniel Gomez Ferro
            Reporter:
            Daniel Gomez Ferro
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated:
              Resolved: