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

Explore reusing the caller's WT_SESSION in getLatestOplogTimestamp

    • Type: Icon: Improvement Improvement
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 6.1.0-rc0
    • Affects Version/s: None
    • Component/s: None
    • None
    • Fully Compatible
    • Execution Team 2022-05-30, Execution Team 2022-06-13, Execution Team 2022-06-27, Execution Team 2022-07-11

      As a spin-off of SERVER-61116, we should investigate the possibility of avoiding a dedicated WT_SESSION in getLatestOplogTimestamp. Determining whether it's possible to reduce the cases where we're required to call getLatestOplogTimestamp may facilitate this task.

      Pasting the relevant comments fromĀ SERVER-61116:

      [...] we've identified a possible way to avoid using a second session in getLatestOplogTimestamp. Because the oplog is a logged table, and because per WT-8601 logged tables are not timestamped, we would potentially be able to reuse the existing recovery unit's session. However doing so would change some of the current visibility behaviour and include uncommitted writes on the operation context. We should determine whether there are consumers relying on this behaviour - seems that waiting for write concern could be potentially affected.

      [...] daniel.gottlieb ran an experiment which didn't seem to detect any call site to surface calls sites of getLatestOplogTimestamp with an open transaction. We should investigate whether we actually need to call getLatestOplogTimestamp for write operations, as in principle writes assign a timestamp to the WUOW, so it should be sufficient for the caller to do any waiting for that time.

            Assignee:
            yujin.kang@mongodb.com Yujin Kang Park
            Reporter:
            josef.ahmad@mongodb.com Josef Ahmad
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

              Created:
              Updated:
              Resolved: