[SERVER-64558] Wait for db critical section on StaleDbVersion Created: 16/Mar/22  Updated: 29/Oct/23  Resolved: 17/Mar/22

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

Type: Bug Priority: Major - P3
Reporter: Tommaso Tocci Assignee: Kaloian Manassiev
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Depends
Problem/Incident
is caused by SERVER-63327 Remove usages of the StaleShardVersio... Closed
Backwards Compatibility: Fully Compatible
Operating System: ALL
Sprint: Sharding EMEA 2022-03-21
Participants:
Linked BF Score: 155

 Description   

In SERVER-63327 we swapped the order of checks performed in DatabaseShardingState::checkDbVersion. If we don't currently know the version for a db we now throw StaleDbVersion ignoring the db critical section, even if a critical section is actually in place for that db.

This means that we will possibly perform a refresh and retry the command locally on the shard even if the db critical section is taken.



 Comments   
Comment by Githook User [ 17/Mar/22 ]

Author:

{'name': 'Kaloian Manassiev', 'email': 'kaloian.manassiev@mongodb.com', 'username': 'kaloianm'}

Message: SERVER-64558 Check for critical section before reading the DB/Collection version
Branch: master
https://github.com/mongodb/mongo/commit/27eb423d6ea3dc3d9be216ea452995ae2e159842

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