Uploaded image for project: 'Drivers'
  1. Drivers
  2. DRIVERS-591

Transaction test runner should use "local" read concern when asserting the final collection state

    • Type: Icon: Bug Bug
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Component/s: None
    • None

      Useful Info

      Lead:
      POCs:

      Summary:
      The transaction spec test runner says:

      #. For each element in ``outcome``:
      
         - If ``name`` is "collection", verify that the test collection contains
           exactly the documents in the ``data`` array. Ensure this find uses
           Primary read preference even when the MongoClient is configured with
           another read preference.
      

      However, when a test configures the client with readConcern=majority and performs a write with w=1, then the subsequent find will run with readConcern=majority and possibly miss the w=1 write depending on the current majority commit point.

      To ensure the find remains causally consistent with previous operations we must use "local" read concern while reading the latest data on the primary.

      Final Specification:
      https://github.com/mongodb/specifications/commit/0b8c2e9cef44848a89ec9b5aceeb3f5382879d46

            Assignee:
            Unassigned Unassigned
            Reporter:
            shane.harvey@mongodb.com Shane Harvey
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: