[DOCS-1] Sequences would be better done by findandmodify Created: 10/Apr/11 Updated: 08/Sep/12 Resolved: 11/Apr/11 |
|
| Status: | Closed |
| Project: | Documentation |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major - P3 |
| Reporter: | Karoly Negyesi | Assignee: | Unassigned |
| Resolution: | Done | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Participants: | |
| Days since reply: | 12 years, 45 weeks, 3 days ago |
| Description |
|
http://www.mongodb.org/display/DOCS/Object+IDs#ObjectIDs-SequenceNumbers links to http://www.mongodb.org/display/DOCS/Atomic+Operations (instead of http://www.mongodb.org/display/DOCS/Atomic+Operations#AtomicOperations-%22InsertifNotPresent%22 ) but that code is not the best concurrency-wise, findandmodify is way better for sequences we do: $cmd = array( |
| Comments |
| Comment by Scott Hernandez (Inactive) [ 11/Apr/11 ] |
|
I added an example using findAndModify w/new+upsert When this was orig. written upsert didn't exist on findAndModify (most likely) |