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

Improved warning for low cardinality keys

    • Type: Icon: Improvement Improvement
    • Resolution: Done
    • Priority: Icon: Major - P3 Major - P3
    • 3.1.4
    • Affects Version/s: None
    • Component/s: Sharding
    • None
    • Fully Compatible
    • None
    • 0
    • None
    • None
    • None
    • None
    • None
    • None

      mongo estimates the "max" reasonable chunk size and warns if that chunk size exceeds that, in a effort to detect low cardinality keys. The error message is:

      Sat May 17 16:10:09.335 [conn164120] warning: chunk is larger than 1024 bytes because of key { field1: "value1", field2: value2 }
      

      A more informative error message like: "warning possible low cardinality for shard key detected <database>.<collection>" would be helpful.

            Assignee:
            david.hows David Hows (Inactive)
            Reporter:
            charlie.page@10gen.com Charlie Page (Inactive)
            Votes:
            1 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated:
              Resolved: