[SERVER-85580] Undo any update on ScopedSetShardRole construction failure Created: 23/Jan/24  Updated: 01/Feb/24  Resolved: 01/Feb/24

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

Type: Bug Priority: Major - P3
Reporter: Silvia Surroca Assignee: Silvia Surroca
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Backports
Depends
depends on SERVER-85911 Get rid of unsetShardRoleForLegacyDDL... Closed
Problem/Incident
is caused by SERVER-64057 Implement a scoped object for setting... Closed
Related
Assigned Teams:
Catalog and Routing
Backwards Compatibility: Fully Compatible
Backport Requested:
v7.3
Sprint: CAR Team 2024-02-05
Participants:
Linked BF Score: 134

 Description   

The ScopedSetShardRole aim is to set a shardVersion and dbVersion into the OperatingShardingState during the object lifespan.

However, if the construction of the object fails, the destructor won't be called so we could end up having an inconsistent OperatingShardingState.

This ticket aims to make sure that any change done on ScopedSetShardRole constructor will be reverted in case of an error.



 Comments   
Comment by Githook User [ 01/Feb/24 ]

Author:

{'name': 'Silvia Surroca', 'email': 'silvia.surroca@mongodb.com', 'username': 'silviasuhu'}

Message: SERVER-85580 Undo any update on ScopedSetShardRole construction failure (#18322)

GitOrigin-RevId: dbc8b1a147093fd9e40bec7350670c2d1f562ce0
Branch: master
https://github.com/mongodb/mongo/commit/828308709ec3270ae6a265f1892dac9515aeb90a

Comment by Silvia Surroca [ 23/Jan/24 ]

Is caused by SERVER-64057, in particular fb608f9 

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