[SERVER-33032] add a DatabaseShardingState containing the databaseVersion as a decoration on Database Created: 31/Jan/18  Updated: 29/Oct/23  Resolved: 26/Feb/18

Status: Closed
Project: Core Server
Component/s: Sharding
Affects Version/s: 3.7.1
Fix Version/s: 3.7.3

Type: Task Priority: Major - P3
Reporter: Esha Maharishi (Inactive) Assignee: Esha Maharishi (Inactive)
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Backwards Compatibility: Fully Compatible
Sprint: Sharding 2018-02-12, Sharding 2018-02-26, Sharding 2018-03-12
Participants:

 Description   

Once SERVER-33022 goes in, the CatalogCache will cache the databaseVersion in its DatabaseInfoEntry.

However, the CatalogCache should not be used for version checking on shards (since the version check must be done under some form of database lock and the CatalogCache refresh does not take a database lock).

Instead, we should create a DatabaseShardingState (analogous to CollectionShardingState), where we can load the databaseVersion for version checking on shards.

We should make the new DatabaseShardingState a decoration on the storage catalog's Database (rather than on the ServiceContext, as the map of CollectionShardingStates is).



 Comments   
Comment by Githook User [ 26/Feb/18 ]

Author:

{'email': 'esha.maharishi@mongodb.com', 'name': 'Esha Maharishi', 'username': 'EshaMaharishi'}

Message: SERVER-33032 add a DatabaseShardingState containing the databaseVersion as a decoration on Database
Branch: master
https://github.com/mongodb/mongo/commit/5e3564a89ed631e2b1372eb455a8344f21089264

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