[SERVER-58418] Fine-grained implementation of the ShardingMigrationCriticalSection Created: 12/Jul/21  Updated: 06/Dec/22  Resolved: 04/Aug/21

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

Type: Task Priority: Major - P3
Reporter: Sergi Mateo Bellido Assignee: [DO NOT USE] Backlog - Sharding EMEA
Resolution: Won't Do Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Depends
is depended on by SERVER-58417 POC: fine-grained collection critical... Closed
Assigned Teams:
Sharding EMEA
Sprint: Sharding EMEA 2021-07-12, Sharding EMEA 2021-07-26, Sharding EMEA 2021-08-09
Participants:

 Description   

The goal of this task is to provide a fine-grained implementation of the ShardingMigrationCriticalSection that allow us to acquire/promote the CS for a chunk range.

More specifically:

  • Offer a way to acquire/promote the CS specifying the chunk range and expose methods to query those values.
  • Note that there are operations such as rename or reshard that require to block the whole collection.
  • We should consider the range as part of the identifier of a CS, in the sense that if the CS was acquired for the range [MIN, 0) but then it is promoted without a range (i.e. as if we want to block the whole collection) it should emit an error.
  • Q: Right now the implementation of [recoverable critical sections|thttps://github.com/mongodb/mongo/blob/master/src/mongo/db/s/sharding_migration_critical_section.h] has exactly the same interface as the ShardingMigrationCriticalSection. This is going to change with this work. As part of this ticket, it would be interesting to check if there is any potential problem.


 Comments   
Comment by Sergi Mateo Bellido [ 04/Aug/21 ]

After discussing it wil Kal we thought that it would be a nicer approach to move the implementation of the CS to a lower level, close to the storage execution. More info on SERVER-58417.

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