[SERVER-31244] Retrying findAndModify should not uassert if upsert=true but the oplog entry is for an update Created: 25/Sep/17  Updated: 06/Dec/22  Resolved: 27/Sep/17

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

Type: Bug Priority: Major - P3
Reporter: Jack Mulrow Assignee: [DO NOT USE] Backlog - Sharding Team
Resolution: Duplicate Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Duplicate
duplicates SERVER-30894 Implement command for retrieving oplo... Closed
Assigned Teams:
Sharding
Backwards Compatibility: Fully Compatible
Operating System: ALL
Participants:

 Description   

When reconstructing the response for findAndModify, if the oplog entry is for an update (opType='u'), there is a uassert that request does not have upsert=true - this should be removed, since upsert=true does not guarantee the request will result in an insert entry in the oplog. I saw randolph included this fix in his review for SERVER-30894, so this ticket can be closed once that is committed.

Failing retryable_writes_jscore_passthrough tests:

  • find_and_modify.js
  • find_and_modify4.js
  • update_find_and_modify_id.js

Generated at Thu Feb 08 04:26:25 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.