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

Improve error message when shard key not present in all documents

    XMLWordPrintable

    Details

    • Backwards Compatibility:
      Fully Compatible
    • Backport Requested:
      v4.0
    • Sprint:
      Sharding 2018-10-22, Sharding 2018-11-05
    • Case:

      Description

      The checkShardingIndex command returns the following error message if any of the documents in the target collection do not contain the shard key fields:

      "code": 96,
      "codeName": "OperationFailed",
      "errmsg": "found missing value in key { : null, : null }"
      

      This error message should be optimized for user-education and next steps. For example it should probably say "Documents missing shard key fields - ensure all documents are updated to include all fields" or similar.

        Attachments

          Activity

            People

            • Votes:
              0 Vote for this issue
              Watchers:
              12 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: