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

Make Counters in MultiUpdateCoordinator Unit Test Atomic

    • Type: Icon: Bug Bug
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 8.0.0-rc0
    • Affects Version/s: None
    • Component/s: Sharding
    • Labels:
      None
    • Fully Compatible
    • ALL
    • Cluster Scalability 2024-2-5
    • 149

      TSAN complains that the counters in the MultiUpdateCoordinator test fixtures are concurrently read and written. These counters are incremented when MultiUpdateCoordinator starts or stops migrations and are read from the unit test. Since the instance should be paused while the unit test reads these values, I think this should be safe, but it's possible that TSAN doesn't have the context to realize that the failpoint is being used as synchronization here.

      These counters should be made atomic so TSAN stops complaining, and if there really is a race in the test we'll see unit test failures due to an unexpected count.

            Assignee:
            brett.nawrocki@mongodb.com Brett Nawrocki
            Reporter:
            brett.nawrocki@mongodb.com Brett Nawrocki
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: