[SERVER-45100] Make the BatchWriteExecutor retry multi-writes only against unsuccessful shards Created: 12/Dec/19  Updated: 29/Oct/23  Resolved: 19/Dec/19

Status: Closed
Project: Core Server
Component/s: Sharding
Affects Version/s: None
Fix Version/s: 4.2.3, 4.3.3, 4.0.15

Type: Task Priority: Major - P3
Reporter: Kaloian Manassiev Assignee: Marcos José Grillo Ramirez
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Backports
Depends
is depended on by SERVER-44598 Shards do not treat the IGNORED versi... Closed
Problem/Incident
causes SERVER-47233 WriteOp can be left in pending state,... Closed
Backwards Compatibility: Fully Compatible
Backport Requested:
v4.2, v4.0
Sprint: Sharding 2019-12-16, Sharding 2019-12-30
Participants:

 Description   

Currently, the BatchWriteExecutor's retry logic for StaleShardVersion handling repeats the entire entry from the batch. This works correctly for batch entries, which contain a shard key, because they go to a single shard. However, for batch entries, which are part of a multi-update, this causes the successful shards to be repeated.

This ticket is about introducing a map, which tracks on which shard a batch entry has succeeded, so that a retry won't send it there. It is a prerequisite for enabling SERVER-44598.



 Comments   
Comment by Githook User [ 14/Jan/20 ]

Author:

{'name': 'Marcos José Grillo Ramírez', 'email': 'marcos.grillo@10gen.com'}

Message: SERVER-45100 Make the BatchWriteExecutor retry multi-writes only against unsuccessful shards

(cherry picked from commit d591387903bc1337acb99219ebea0a5d1fb99071)
(cherry picked from commit 84af3af3b0505c43262c3b27c2170a46d5a49d89)
Branch: v4.0
https://github.com/mongodb/mongo/commit/f363b73df0d73def72088093851464272702217a

Comment by Githook User [ 09/Jan/20 ]

Author:

{'name': 'Marcos José Grillo Ramírez', 'email': 'marcos.grillo@10gen.com'}

Message: SERVER-45100 Make the BatchWriteExecutor retry multi-writes only against unsuccessful shards

(cherry picked from commit d591387903bc1337acb99219ebea0a5d1fb99071)
Branch: v4.2
https://github.com/mongodb/mongo/commit/84af3af3b0505c43262c3b27c2170a46d5a49d89

Comment by Githook User [ 19/Dec/19 ]

Author:

{'name': 'Marcos José Grillo Ramírez', 'email': 'marcos.grillo@10gen.com'}

Message: SERVER-45100 Make the BatchWriteExecutor retry multi-writes only against unsuccessful shards
Branch: master
https://github.com/mongodb/mongo/commit/d591387903bc1337acb99219ebea0a5d1fb99071

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