[SERVER-77116] Checking shard version during restore can cause StaleConfig exception propagated for writes incorrectly Created: 14/May/23  Updated: 29/Oct/23  Resolved: 22/Jun/23

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

Type: Bug Priority: Major - P3
Reporter: Yuhong Zhang Assignee: Jordi Serra Torrens
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Depends
Problem/Incident
causes SERVER-78470 Prevent multi-false UpdateStage/Delet... Closed
is caused by SERVER-74087 Thread-through `ScopedCollectionOrVie... Closed
is caused by SERVER-76168 Thread-through `ScopedCollectionOrVie... Closed
Related
related to SERVER-78355 Complete TODO listed in SERVER-77116 Closed
is related to SERVER-79408 Apply SERVER-77116 and SERVER-78470 t... Closed
Assigned Teams:
Sharding EMEA
Backwards Compatibility: Fully Compatible
Operating System: ALL
Sprint: Sharding EMEA 2023-05-29, Sharding EMEA 2023-06-12, Sharding EMEA 2023-06-26
Participants:
Linked BF Score: 108

 Description   

This is a follow-up investigation for the duplicate time-series inserts issue. Besides SERVER-77063, it seems inserts that don't perform any compression can also result in duplicate measurements when there's a concurrent chunk migration. The logging implied that the write to storage succeeded while a StaleConfig exception was also thrown.

SERVER-74087 introduced the check of shard version during restore in query stages. This can cause the StaleConfig exception returned incorrectly which can lead to data inconsistencies.



 Comments   
Comment by Githook User [ 27/Jul/23 ]

Author:

{'name': 'Jordi Serra Torrens', 'email': 'jordi.serra-torrens@mongodb.com', 'username': 'jordist'}

Message: SERVER-79408 Apply SERVER-77116 and SERVER-78470 to TimeseriesModifyStage
Branch: master
https://github.com/mongodb/mongo/commit/ff6797a6537808eb04976192fa98f81936c2493f

Comment by Githook User [ 22/Jun/23 ]

Author:

{'name': 'Jordi Serra Torrens', 'email': 'jordi.serra-torrens@mongodb.com', 'username': 'jordist'}

Message: SERVER-77116 Prevent multi:false writes from throwing StaleConfig after having done one write
Branch: master
https://github.com/mongodb/mongo/commit/e9e13df72d9da6d276381cdd7972ada23905c345

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