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

Relax rules on setting readOnce flag on WiredTiger session

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Major - P3
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 4.1.4
    • Component/s: Storage
    • Labels:
      None
    • Backwards Compatibility:
      Fully Compatible
    • Sprint:
      Repl 2018-10-22

      Description

      A WiredTiger transaction may be started before mongod 'find' or 'getMore' command execution begins, through readConcern or multi-statement transaction execution. If the readOnce flag is not permitted to be set with a storage transaction active, this will result in an invariant if we attempt to set readOnce in the 'find' or 'getMore' execution path. Additionally, the fact that a transaction is active is not directly exposed to the upper layers (i.e. RecoveryUnit has no inActiveTxn()), so this is difficult to reliably prevent.

      Since this restriction is not required by WiredTiger itself, we can relax the API to allow the readOnce flag to be set if and only if no cursors are open, even if a transaction is open.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              matthew.russotto Matthew Russotto
              Reporter:
              matthew.russotto Matthew Russotto
              Participants:
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: