[SERVER-895] handle _id shard key w/o _id specified. Sharding example in docs shows sharding gridfs based on _id column, but this fails with error on insert "UserException: tried to insert object without shard key" Created: 19/Nov/09  Updated: 12/Jul/16  Resolved: 19/Nov/09

Status: Closed
Project: Core Server
Component/s: Sharding
Affects Version/s: None
Fix Version/s: 1.1.4

Type: Bug Priority: Major - P3
Reporter: Jayson Minard Assignee: Eliot Horowitz (Inactive)
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Participants:

 Description   

Instead of _id you can instead use files_id to shard possibly?



 Comments   
Comment by auto [ 19/Nov/09 ]

Author:

{'name': 'Eliot Horowitz', 'email': 'eliot@10gen.com'}

Message: fix sharding on _id when _id is missing SHARDING-55
http://github.com/mongodb/mongo/commit/daaa53c4c52727a8e47e14da060ad436191c4555

Comment by auto [ 19/Nov/09 ]

Author:

{'name': 'Eliot Horowitz', 'email': 'eliot@10gen.com'}

Message: fix sharding on _id when _id is missing SHARDING-55
http://github.com/mongodb/mongo/commit/daaa53c4c52727a8e47e14da060ad436191c4555

Comment by auto [ 19/Nov/09 ]

Author:

{'name': 'Eliot Horowitz', 'email': 'eliot@10gen.com'}

Message: fix sharding on _id when _id is missing SHARDING-55
http://github.com/mongodb/mongo/commit/daaa53c4c52727a8e47e14da060ad436191c4555

Comment by auto [ 19/Nov/09 ]

Author:

{'name': 'Eliot Horowitz', 'email': 'eliot@10gen.com'}

Message: fix sharding on _id when _id is missing SHARDING-55
http://github.com/mongodb/mongo/commit/daaa53c4c52727a8e47e14da060ad436191c4555

Comment by auto [ 19/Nov/09 ]

Author:

{'name': 'Eliot Horowitz', 'email': 'eliot@10gen.com'}

Message: fix sharding on _id when _id is missing SHARDING-55
http://github.com/mongodb/mongo/commit/daaa53c4c52727a8e47e14da060ad436191c4555

Comment by auto [ 19/Nov/09 ]

Author:

{'name': 'Eliot Horowitz', 'email': 'eliot@10gen.com'}

Message: fix sharding on _id when _id is missing SHARDING-55
http://github.com/mongodb/mongo/commit/daaa53c4c52727a8e47e14da060ad436191c4555

Comment by auto [ 19/Nov/09 ]

Author:

{'name': 'Eliot Horowitz', 'email': 'eliot@10gen.com'}

Message: fix sharding on _id when _id is missing SHARDING-55
http://github.com/mongodb/mongo/commit/daaa53c4c52727a8e47e14da060ad436191c4555

Comment by auto [ 19/Nov/09 ]

Author:

{'name': 'Eliot Horowitz', 'email': 'eliot@10gen.com'}

Message: fix sharding on _id when _id is missing SHARDING-55
http://github.com/mongodb/mongo/commit/daaa53c4c52727a8e47e14da060ad436191c4555

Comment by auto [ 19/Nov/09 ]

Author:

{'name': 'Eliot Horowitz', 'email': 'eliot@10gen.com'}

Message: fix sharding on _id when _id is missing SHARDING-55
http://github.com/mongodb/mongo/commit/daaa53c4c52727a8e47e14da060ad436191c4555

Comment by Eliot Horowitz (Inactive) [ 19/Nov/09 ]

you can use files_id
the problem is with gridfs clients that don't add _id automatically.

Generated at Thu Feb 08 02:55:28 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.