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

Ignore all errors where $collStats indicates that a collection is empty in the analyzeShardKey background hook

    • Type: Icon: Task Task
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 8.1.0-rc0
    • Affects Version/s: None
    • Component/s: None
    • None
    • Cluster Scalability
    • Fully Compatible
    • 0
    • None
    • 3
    • None
    • None
    • None
    • None
    • None
    • None

      $collStats returns storageStats that are read from the in-memory WT record store, which can be slightly outdated (the count value is what we typically refer to as the "fastCount" value). Currently, the analyzeShardKey background hook will an error thrown by analyzeShardKey if $collStats returns 0 for the count value. However, it doesn't ignore the error if the count is > 0 but the dataSize is 0. The dataSize value is updated just after the count value, so it's possible that we've updated the count value after a recent insert, and not yet the dataSize value, so this error should be acceptable as well.

            Assignee:
            janna.golden@mongodb.com Janna Golden
            Reporter:
            janna.golden@mongodb.com Janna Golden
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: