Details
-
Improvement
-
Resolution: Done
-
Critical - P2
-
None
-
*Location*: http://docs.mongodb.org/manual/tutorial/enforce-unique-keys-for-sharded-collections/
*User-Agent*: Mozilla/5.0 (X11; Linux x86_64; rv:26.0) Gecko/20100101 Firefox/26.0
*Referrer*: http://docs.mongodb.org/manual/reference/limits/
*Screen Resolution*: 2560 x 1440
*repo*: docs
*source*: tutorial/enforce-unique-keys-for-sharded-collections
*Location*: http://docs.mongodb.org/manual/tutorial/enforce-unique-keys-for-sharded-collections/ *User-Agent*: Mozilla/5.0 (X11; Linux x86_64; rv:26.0) Gecko/20100101 Firefox/26.0 *Referrer*: http://docs.mongodb.org/manual/reference/limits/ *Screen Resolution*: 2560 x 1440 *repo*: docs *source*: tutorial/enforce-unique-keys-for-sharded-collections
Description
footnote 1 makes it seem like we let you create a unique index on a sharded collection and just fail to enforce it. We don't. Creating new unique indexes will fail, and we refuse to shard collections with unique indexes on fields other than _id. The footnote as-is (and much of this page) only applies to the _id index.
Also the Warning should probably be presented as a 3rd option: using guaranteed unique identifiers.