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

ChunkManager::getShardIdsForRange invariants when max = MaxKey

    XMLWordPrintable

Details

    • Fully Compatible
    • ALL
    • Sharding 2018-09-10
    • 2

    Description

      The ChunkManager::getShardIdsForRange call contains an invariant to ensure that the range it is passed is contained within the shard key space for the collection.

      However, this invariant is incorrect when the range ends in MaxKey, because MaxKey is not a valid key value. The invariant should be extended to account for MaxKey and as part of fixing this we should write unit-tests to validate this logic.

      This bug does not exist in versions 4.0 and later, because we use a different structure for the chunk ranges.

      Attachments

        Activity

          People

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

            Dates

              Created:
              Updated:
              Resolved: