[SERVER-39841] If write isn't in multi-stmt txn mongos should start internal transaction and run the original update command Created: 26/Feb/19  Updated: 29/Oct/23  Resolved: 18/Mar/19

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

Type: Task Priority: Major - P3
Reporter: Janna Golden Assignee: Janna Golden
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Backwards Compatibility: Fully Compatible
Sprint: Sharding 2019-03-25
Participants:

 Description   

SERVER-39835 creates logic to run a delete-insert transaction from mongos upon receiving WouldChangeOwningShard. If the original write command is not part of a multi-stmt transaction, instead of creating and running delete and insert command objects we will instead start a transaction and run the original write command. This command should use the original query predicate and updates attached to the WCOS as its query and update fields. Once this returns successfully, commit this transaction.



 Comments   
Comment by Githook User [ 18/Mar/19 ]

Author:

{'email': 'golden.janna@gmail.com', 'name': 'jannaerin', 'username': 'jannaerin'}

Message: SERVER-39841 Add ability to start and commit transaction in documentShardKeyUpdateUtil
Branch: master
https://github.com/mongodb/mongo/commit/a1e0c7194f90ca8fb2bf5889b6c42b307cccc03f

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