[SERVER-5198] incorrect assumptions in write operations using cursors Created: 05/Mar/12  Updated: 28/Sep/21  Resolved: 14/May/12

Status: Closed
Project: Core Server
Component/s: Querying
Affects Version/s: None
Fix Version/s: 2.1.2

Type: Bug Priority: Major - P3
Reporter: Aaron Staple Assignee: Aaron Staple
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Related
related to SERVER-5725 streamline cursor advancement on write Closed
related to SERVER-60264 clean up orp.js Closed
Operating System: ALL
Participants:

 Description   
  • delete asserts if getsetdup identifies a dup, however a duplicate location is possible if the original document was removed and its record was reused for a new document
  • update and delete have a policy of avoiding a full yield by advancing to a subsequent record before a record is modified. This will not work correctly if advance() transitions to a new $or clause that has a basic cursor pointing at the document that will be deleted/updated. (With a basic cursor, the noteLoc() / checkLoc() code won't help - the cursor needs to be advanced beyond the modification point.)


 Comments   
Comment by auto [ 13/May/12 ]

Author:

{u'login': u'astaple', u'name': u'Aaron', u'email': u'aaron@10gen.com'}

Message: SERVER-5198 Add a test for a clause transition deletion case.
Branch: master
https://github.com/mongodb/mongo/commit/f34ec97947ea227145b402ed0329b583881f4d39

Comment by auto [ 13/May/12 ]

Author:

{u'login': u'astaple', u'email': u'aaron@10gen.com', u'name': u'Aaron'}

Message: SERVER-5198 Remove outdated comments.
Branch: master
https://github.com/mongodb/mongo/commit/97db2e76d14c2b15512139fca7cd40d8768ebd5b

Comment by auto [ 13/May/12 ]

Author:

{u'login': u'astaple', u'name': u'Aaron', u'email': u'aaron@10gen.com'}

Message: SERVER-5198 Advance past documents before modifying them in write operations.
Branch: master
https://github.com/mongodb/mongo/commit/713627d22201a9698f106bb331a35c1ac61a5cde

Comment by auto [ 13/May/12 ]

Author:

{u'login': u'astaple', u'name': u'Aaron', u'email': u'aaron@10gen.com'}

Message: SERVER-5198 Advance MultiCursor to subsequent clauses if the last entry for a clause is removed by a document update on yield.
Branch: master
https://github.com/mongodb/mongo/commit/b2d0883ba1450073e2b7fdd11fda8bbbbc26cee0

Comment by auto [ 28/Apr/12 ]

Author:

{u'login': u'astaple', u'name': u'Aaron', u'email': u'aaron@10gen.com'}

Message: SERVER-5198 Don't check for dups in the remove implementation.
Branch: master
https://github.com/mongodb/mongo/commit/b3c9b5c9068aaa35d1e9a91a35cdb0f7227e98fd

Comment by auto [ 23/Mar/12 ]

Author:

{u'login': u'astaple', u'name': u'Aaron', u'email': u'aaron@10gen.com'}

Message: SERVER-4150 SERVER-5198 Don't advance a duplicate entry on takeover when mixed in order and out of order plans are possible.
Branch: master
https://github.com/mongodb/mongo/commit/589cd70e74fa778cb08f41bd44675197a35b7bc0

Generated at Thu Feb 08 03:08:11 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.