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

findOne in analyzeShardKeyBackground hook can return queryPlanKilled

    • Type: Icon: Bug Bug
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 8.1.0-rc0
    • Affects Version/s: None
    • Component/s: None
    • None
    • Cluster Scalability
    • Fully Compatible
    • ALL
    • Cluster Scalability 2024-12-23
    • 0

      The background hook for analyzeShardKey calls a findOne on the collection to get a random document from which a random shard key to be analyzed is generated from. It's possible for this find throws a queryPlanKilled error if the collection was dropped in between the time of getting the collection and sending the find(see BF-36026).

      Wrap the findOne in a try/catch condition and return early if queryPlanKilled is thrown.

            Assignee:
            kruti.shah@mongodb.com Kruti Shah
            Reporter:
            kruti.shah@mongodb.com Kruti Shah
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: