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

Collection sample counters not removed atomically with sample reconfiguration

    • Type: Icon: Bug Bug
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 7.0.0-rc0
    • Affects Version/s: 7.0.0-rc0
    • Component/s: None
    • Fully Compatible
    • ALL
    • 147
    • 1

      In BF-28001, one writing thread is generating a sample ID and invokes the collection's sample counters. In another thread, query sampling on this collection is being disabled, and the collection's sample counters are removed first, and then the collection's sampling configuration is removed. Because these two removals do not happen atomically, the writing thread decides to generate a sample ID, but then an invariant is false when it cannot fetch the collection's sample counters.

      The removal of a sampling configuration and the removal of the collection's sample counters must occur atomically, within QueryAnalysisSampler::_refreshConfigurations().

            Assignee:
            israel.hsu@mongodb.com Israel Hsu
            Reporter:
            israel.hsu@mongodb.com Israel Hsu
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: