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

Extend test/format to test for transactions reading their writes

    • Type: Icon: Bug Bug
    • Resolution: Done
    • Priority: Icon: Major - P3 Major - P3
    • WT2.9.0
    • Affects Version/s: None
    • Component/s: None
    • None

      In WT-2534 we spent a lot of time adding diagnostics to track down a bug found when porting to a system with a weaker memory model than x86.

      It would be helpful to have the following simple test for lost updates, which I believe would have failed on the test system:

      create a table with one record, value_format=q, initial value zero
      In N threads:
        count = 0
        while count < 1000:
          begin a transaction with isolation=snapshot
          read $value
          update with $value+1, rollback and continue on failure
          commit
          increment count
      
      Join all threads, verify that the value is 1000 * N.
      

        1. t4.c
          4 kB

            Assignee:
            alexander.gorrod@mongodb.com Alexander Gorrod
            Reporter:
            michael.cahill@mongodb.com Michael Cahill (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: