[SERVER-46199] Implement collection cache on top of ReadThroughCache to make it causally consistent Created: 15/Feb/20  Updated: 29/Oct/23  Resolved: 09/Sep/20

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

Type: Task Priority: Major - P3
Reporter: Kaloian Manassiev Assignee: Tommaso Tocci
Resolution: Fixed Votes: 0
Labels: PM-1645-Milestone-2
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Depends
depends on SERVER-46154 Make ReadThroughCache be driven by a ... Closed
depends on SERVER-48990 Introduce ComparableChunkVersion class Closed
depends on SERVER-49190 Expose a function to iterate over all... Closed
depends on SERVER-50272 Make RoutingTableHistory movable Closed
is depended on by SERVER-50812 Remove the SetShardVersion command Closed
is depended on by SERVER-50815 Improve database and collection versi... Closed
Duplicate
is duplicated by SERVER-50042 Set shouldBlockBehindCatalogCacheRefr... Closed
Issue split
split from SERVER-48991 Make CatalogCache causally consistent Closed
Problem/Incident
causes SERVER-50952 Ensure that cached collection entries... Closed
Backwards Compatibility: Fully Compatible
Sprint: Sharding 2020-07-13, Sharding 2020-06-29, Sharding 2020-07-27, Sharding 2020-08-24, Sharding 2020-09-21
Participants:
Linked BF Score: 50

 Description   

This task is to implement the Collection cache on top of ReadThroughCache in order to make it causally consistent.

Ideally databases and collections should ideally be stored in two different cache objects and tracked independently and the retrieval of the Database + Collection combination for the unsharded case should be a syntactic sugar on top of it, rather than the current implementation, which stores them as two hierarchical caches.



 Comments   
Comment by Githook User [ 11/Sep/20 ]

Author:

{'name': 'Marcos José Grillo Ramírez', 'email': 'marcos.grillo@mongodb.com', 'username': 'm4nti5'}

Message: SERVER-46199 Make the collection CatalogCache support causal consistency

This change implements the collection CatalogCache on top of the
ReadThroughCache, giving it the ability to support causal consistency.
As part of this change, the 'forceRefreshFromThisThread' flag has been
removed from the shard's refresh methods.

Co-authored-by: Tommaso Tocci <tommaso.tocci@mongodb.com>
Co-authored-by: Pierlauro Sciarelli <pierlauro.sciarelli@mongodb.com>
Co-authored-by: Kaloian Manassiev <kaloian.manassiev@mongodb.com>
Branch: svilen-optimizer-poc
https://github.com/mongodb/mongo/commit/377b8fe43916ff2c4e2ed35cb80548aeb8ba8c8d

Comment by Githook User [ 09/Sep/20 ]

Author:

{'name': 'Marcos José Grillo Ramírez', 'email': 'marcos.grillo@mongodb.com', 'username': 'm4nti5'}

Message: SERVER-46199 Make the collection CatalogCache support causal consistency

This change implements the collection CatalogCache on top of the
ReadThroughCache, giving it the ability to support causal consistency.
As part of this change, the 'forceRefreshFromThisThread' flag has been
removed from the shard's refresh methods.

Co-authored-by: Tommaso Tocci <tommaso.tocci@mongodb.com>
Co-authored-by: Pierlauro Sciarelli <pierlauro.sciarelli@mongodb.com>
Co-authored-by: Kaloian Manassiev <kaloian.manassiev@mongodb.com>
Branch: master
https://github.com/mongodb/mongo/commit/377b8fe43916ff2c4e2ed35cb80548aeb8ba8c8d

Comment by Githook User [ 05/Sep/20 ]

Author:

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

Message: SERVER-46199 Fix CollectionShardingState <-> CatalogCache destruction order in unit-tests
Branch: master
https://github.com/mongodb/mongo/commit/8a86a51758f4913fd21f01408a402e5a6f787ea5

Comment by Githook User [ 04/Sep/20 ]

Author:

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

Message: SERVER-46199 Get rid of the BM_IncrementalRefreshWithNoChange benchmark

This test is incompatible with making the RoutingTableHistory movable,
done under 3df9c61b7747058cd84edd7a875b1524db57dd1d. In order to
preserve the same performance characteristic, the check for whether any
changes have happened to the routing info was pulled at a higher level,
in the CatalogCache.
Branch: master
https://github.com/mongodb/mongo/commit/3f9e675017474fd53b6cc149ea492aed95b8c92d

Comment by Githook User [ 03/Sep/20 ]

Author:

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

Message: SERVER-46199 Make the RoutingTableHistory movable
Branch: master
https://github.com/mongodb/mongo/commit/3df9c61b7747058cd84edd7a875b1524db57dd1d

Comment by Githook User [ 03/Sep/20 ]

Author:

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

Message: SERVER-46199 Hide the RoutingTableHistory detail from the ChunkManager
Branch: master
https://github.com/mongodb/mongo/commit/e9b6548c82815c7fb900ee7c00e497660a7d610c

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