Command with snapshot read concern without 'atClusterTime' can fail with SnapshotTooOld

XMLWordPrintableJSON

    • Type: Bug
    • Resolution: Works as Designed
    • Priority: Major - P3
    • None
    • Affects Version/s: None
    • Component/s: None
    • None
    • ALL
    • Repl 2021-04-05
    • None
    • 3
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      In snapshot read concern, when the client does not specify an 'atClusterTime', the server will chose one in the command entry point to be the CurrentCommittedSnapshotOpTime. However, when the command gets executed, the currentCommitedSnapshotOpTime in the node could already have been advanced beyond the minSnapshotHistoryWindowInSeconds, so the command would fail to open the cursor and return SnapshotTooOld. This is because the selection of the opTime to read and the opening of the cursor does not happen atomically.
      The client can retry on that error, but it seems that this situation can potentially keep happening on retries. Thus the client can't deterministically get that query to eventually succeed.

            Assignee:
            Lingzhi Deng
            Reporter:
            Jordi Serra Torrens
            Votes:
            0 Vote for this issue
            Watchers:
            9 Start watching this issue

              Created:
              Updated:
              Resolved: