[DOCS-41] Remove all mention of using an object as location in geo docs Created: 19/Aug/11  Updated: 08/Sep/12  Resolved: 06/Apr/12

Status: Closed
Project: Documentation
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Improvement Priority: Major - P3
Reporter: Mathias Stearn Assignee: Sam Kleinman (Inactive)
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Participants:
Days since reply: 11 years, 45 weeks, 5 days ago

 Description   

Using an object is fragile since order matters and many drivers don't preserve order when fetching data. Should always use an array.



 Comments   
Comment by auto [ 06/Apr/12 ]

Author:

{u'login': u'tychoish', u'name': u'Sam Kleinman', u'email': u'samk@10gen.com'}

Message: DOCS-41: style guide updates
Branch: master
https://github.com/mongodb/docs/commit/3d552509ffe6b6fffb8af5c05b694d028efed47b

Comment by Sam Kleinman (Inactive) [ 06/Apr/12 ]

Updated document to reflect this.

Comment by Mathias Stearn [ 02/Apr/12 ]

To be clear, this ticket was referring to things like this on the geo page:

"In order to use the index, you need to have a field in your object that is either a sub-object or array where the first 2 elements are x,y coordinates (or y,x - just be consistent; it might be advisable to use order-preserving dictionaries/hashes in your client code, to ensure consistency)."

We should never mention that we support objects in the location field (even though we must for compatibility). The docs should just tell them to use an array without any other options.

Comment by auto [ 30/Mar/12 ]

Author:

{u'login': u'tychoish', u'name': u'Sam Kleinman', u'email': u'samk@10gen.com'}

Message: DOCS-41: style guide tweak
Branch: master
https://github.com/mongodb/docs/commit/1841a44f2446689701af7b3504b0644f3318b397

Comment by Sam Kleinman (Inactive) [ 30/Mar/12 ]

I just added the following:

Do not refer to documents as "objects," because drivers (and MongoDB)
do not preserve the order of fields when fetching data. If the order
of objects matter, use an array.

to the style guide under the "document," item in the jargon section. I don't think there are any instances of this in the Manual (nee new docs), but I think the best course of action is to get the above comment correct, and then close this ticket, and open new issues as needed against the Manual if there are specific instances of this error.

Would you suggest a different process?

Generated at Thu Feb 08 07:37:48 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.