Uploaded image for project: 'WiredTiger'
  1. WiredTiger
  2. WT-5393

Prepared transaction rollback and API error handling fixes

    • Type: Icon: Bug Bug
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • WT10.0.0, 4.2.4, 4.3.4
    • Affects Version/s: None
    • Component/s: None
    • None
    • 3
    • Storage Engines 2020-01-13, Storage Engines 2020-01-27, Storage Engines 2020-02-10
    • v4.2

      Summary:

      Fix problems in prepared transaction API to fail attempted operations after a prepare without forcing the transaction to rollback, and panic the system if a prepared transaction cannot be subsequently committed.


       

      The changes in WT-5324 have a problem: the test for WT_SESSION.rollback_transaction as the caller in the __wt_txn_err_chk() function call was wrong, always returning success.

      Using the correct test reveals an underlying problem, we need to allow at least WT_CURSOR.reset and WT_CURSOR.close calls in cases where an error has already occurred within a transaction.

      Additionally, under some conditions, prepared transactions can be rolled back, which violates transactional semantics.

            Assignee:
            keith.bostic@mongodb.com Keith Bostic (Inactive)
            Reporter:
            keith.bostic@mongodb.com Keith Bostic (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: