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

Race condition between addShard and ShardRegistry reload

    XMLWordPrintable

Details

    • Bug
    • Status: Closed
    • Major - P3
    • Resolution: Fixed
    • 3.2.5, 3.3.5
    • 3.2.8, 3.3.6
    • Sharding
    • Fully Compatible
    • ALL
    • 0

    Description

      If one thread starts reloading the shard registry, all other calls to reload will block waiting for it to complete. If addShard runs concurrently with the reload, it is possible that the initial reload will not see the newly added shard and the reload initiated by addShard will do nothing, assuming that the first reload saw the latest state.

      This is a race condition, which can cause shardCollection calls with sharded key to not use newly added shards.

      Attachments

        Activity

          People

            kaloian.manassiev@mongodb.com Kaloian Manassiev
            kaloian.manassiev@mongodb.com Kaloian Manassiev
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: