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

Refactor how WiredTigerRecoveryUnit and WiredTigerSnapshotManager begin transactions at points in time

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major - P3
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 4.0.0
    • Component/s: Storage
    • Labels:
      None
    • Backwards Compatibility:
      Fully Compatible
    • Operating System:
      ALL
    • Sprint:
      Storage NYC 2018-05-07, Storage NYC 2018-05-21

      Description

      There are 4 different Timestamp member variables and equally as many booleans to track how we open transactions, timestamp transactions, and commit transactions. The relationship between the recovery unit and the snapshot manager is equally as confusing.

      There are 5 ways to open a transaction and 2 ways to commit.

      On top of that, the ignore_prepare flag has to be set in each of the 5 places we begin transactions, and sometimes with additional configuration parameters.

      My suggestions for improvement (at a minimum) are:

      • Only call begin_transaction in one place, potentially as a helper on the WiredTigerSession or the RecoveryUnit itself.
      • Use an enum to keep track of what type of read/commit we are doing for the open transaction.
      • To reduce timestamp confusion we should only have to keep track of 2 timestamps: when to read and when to commit.
      • The SnapshotManager should only keep track of timestamps (or removed completely), and not be the designated caller to open special types of transactions.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              louis.williams Louis Williams
              Reporter:
              louis.williams Louis Williams
              Participants:
              Votes:
              0 Vote for this issue
              Watchers:
              7 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: