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

Unprotected concurrent access to coordinator doc member variable by DDL coordinator implementations

    • Type: Icon: Task Task
    • Resolution: Duplicate
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: None
    • Component/s: None
    • Labels:
      None
    • Sharding EMEA

      Current implementations of some DDL coordinators access the _doc member variable inside checkIfOptionsConflict and reportCurrentOp without any concurrency control even though it can be modified when _runImpl is being executed.

      For example, in RefineCollectionShardKeyCoordinator coordinator doc is read here:
      https://github.com/10gen/mongo/blob/b4384a6a6774ae494e57adc0c625769fec107828/src/mongo/db/s/refine_collection_shard_key_coordinator.cpp#L71
      https://github.com/10gen/mongo/blob/b4384a6a6774ae494e57adc0c625769fec107828/src/mongo/db/s/refine_collection_shard_key_coordinator.cpp#L82

      And modified here:
      https://github.com/10gen/mongo/blob/b4384a6a6774ae494e57adc0c625769fec107828/src/mongo/db/s/refine_collection_shard_key_coordinator.cpp#L114

            Assignee:
            backlog-server-sharding-emea [DO NOT USE] Backlog - Sharding EMEA
            Reporter:
            randolph@mongodb.com Randolph Tan
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: