Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-22945

Rewrite update_yield1.js to not depend heavily on timing

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Major - P3
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 3.2.5, 3.3.3
    • Component/s: Querying
    • Labels:
    • Backwards Compatibility:
      Fully Compatible
    • Backport Completed:
    • Sprint:
      Query 11 (03/14/16)
    • Linked BF Score:
      0

      Description

      The test update_yield1.js is designed to verify that a long-running multi-update yields to a findOne() operation. However, it depends heavily on timing information and has been shown to be flaky when the test runs slowly.

      We can test the same behavior in a much more dependable way as follows:

      • Start a mongod and configure internalQueryExecYieldIterations so that operations will yield predictably.
      • Insert some data and explain a multi-update which would update all of the data.
      • Assert that the number of yields reported in the explain execution stats is greater than or equal to some value.

        Attachments

          Issue Links

            Activity

              People

              • Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: