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

Extend test/format to test for transactions reading their writes

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major - P3
    • Resolution: Done
    • None
    • WT2.9.0
    • None
    • None

    Description

      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.
      

      Attachments

        1. t4.c
          4 kB

        Activity

          People

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

            Dates

              Created:
              Updated:
              Resolved: