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

Validate commit and durability timestamps at transaction commit

    • Storage Engines

      daniel.gottlieb points out:

      The commit timestamp is not re-checked against stable at commit time. So, this script fails:

      self.conn.set_timestamp('stable_timestamp=' + self.timestamp_str(10))
      cself.conn.set_timestamp('stable_timestamp=' + self.timestamp_str(10))
      c = self.session.open_cursor('table:xxx')
      self.session.begin_transaction()
      c[5] = 'xxx'
      self.conn.set_timestamp('stable_timestamp=' + self.timestamp_str(30))
      self.session.commit_transaction('commit_timestamp=' + self.timestamp_str(20))
      

      fails with:

      __wt_txn_set_commit_timestamp, 568: commit timestamp (0, 20) must be after the stable timestamp (0, 30)
      

      but setting the commit timestamp before stable is set succeeds:

      self.conn.set_timestamp('stable_timestamp=' + self.timestamp_str(10))
      c = self.session.open_cursor('table:xxx')
      self.session.begin_transaction()
      c[5] = 'xxx'
      self.session.timestamp_transaction('commit_timestamp=' + self.timestamp_str(20))
      self.conn.set_timestamp('stable_timestamp=' + self.timestamp_str(30))
      self.session.commit_transaction()
      

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

              Created:
              Updated:
              Resolved: