[SERVER-54474] Introduce the _flushReshardingStateChange command Created: 11/Feb/21  Updated: 29/Oct/23  Resolved: 23/Mar/21

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

Type: Task Priority: Major - P3
Reporter: Haley Connelly Assignee: Janna Golden
Resolution: Fixed Votes: 0
Labels: PM-234-M3, PM-234-T-lifecycle
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Gantt Dependency
has to be done before SERVER-55100 Test functionality of aborting a resh... Closed
Related
related to SERVER-55852 Shards first acquire LockManager lock... Closed
Backwards Compatibility: Fully Compatible
Sprint: Sharding 2021-03-22, Sharding 2021-04-05
Participants:
Story Points: 2

 Description   

command: _flushReshardingStateChanges(nss for shard to refresh on)

context:
In resharding, _flushRoutingTableCacheUpdatesWithWriteConcern is not safe to call when in the critical section. 
SERVER-53258 introduces the _shardsvrFinishReshardCollection for when the coordinator persists its decision in the success case.

However, when the coordinator errors, it is possible that the error will occur while the critical section is engaged. 

This command should combine the logic for _shardsvrFinishReshardCollection and _flushRoutingTableCache++UpdatesWithWriteConcern so it is safe to call regardless of whether the shard refreshing is in the critical section.

logic inside command
if (critical section is held)

{ // ... do _shardsvrFinishReshardCollection behavior }

else

{ // ... do _flushRoutingTableCacheUpdates behavior }

 



 Comments   
Comment by Max Hirschhorn [ 30/Mar/21 ]

Author:

{'name': 'jannaerin', 'email': 'golden.janna@gmail.com', 'username': 'jannaerin'}

Message: SERVER-54474 Introduce the _flushReshardingStateChange command
Branch: master
https://github.com/mongodb/mongo/commit/e2fd2c731ce8a1cd5cf5cf3a43da8b7fdf81ac22

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