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

Reload shard registry before attempting to get number of shards in ShardRegistry::getNumShards()

    XMLWordPrintableJSON

Details

    • Icon: Improvement Improvement
    • Resolution: Gone away
    • Icon: Major - P3 Major - P3
    • None
    • 3.6.11, 4.0.9, 4.1.7
    • Sharding
    • None

    Description

      If getNumShards() returns before the shard registry is populated, it's possible that it can incorrectly return that zero shards exist.

      This function is only used in one place.

      This ticket is simply to either:

      1. Remove this function and replace with getAllShardIds(), which does do a reload, or:
      2. Add a reload inside getNumShards() if the number turns out to be zero.

      Attachments

        Activity

          People

            tommaso.tocci@mongodb.com Tommaso Tocci
            blake.oler@mongodb.com Blake Oler
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: