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

Index builds must ensure a storage transaction is active to correctly ignore prepare conflicts

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major - P3
    • Resolution: Duplicate
    • Affects Version/s: 4.2.0
    • Fix Version/s: None
    • Component/s: None
    • Labels:
      None
    • Operating System:
      ALL

      Description

      The collection scan stage of index builds is not guaranteed to perform reads inside of a transaction. This is not normally problematic, because WiredTiger still guarantees snapshot isolation. The flag to ignore prepare conflicts with "ignore_prepare=true" is set on the call to "begin_transaction, so If no transaction is open, prepare conflicts will not be ignored.

      The cursor used by the collection scan stage opens a transaction implicitly by a call to getSession(). The WriteUnitOfWork::commit() during index build collection scans ends the current WT transaction, and inactivates the RecoveryUnit. Any subsequent cursor operation will use a valid cursor, but not inside of a transaction, and not ignoring prepare conflicts.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              backlog-server-execution Backlog - Execution Team
              Reporter:
              louis.williams Louis Williams
              Participants:
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: