[SERVER-58747] The ShardServerCatalogCacheLoader doesn't interrupt ongoing operations on step up Created: 22/Jul/21  Updated: 29/Oct/23  Resolved: 23/Jul/21

Status: Closed
Project: Core Server
Component/s: Sharding
Affects Version/s: None
Fix Version/s: 5.0.2, 5.1.0-rc0, 4.4.16, 4.2.22

Type: Bug Priority: Major - P3
Reporter: Sergi Mateo Bellido Assignee: Sergi Mateo Bellido
Resolution: Fixed Votes: 0
Labels: SSCCL-BUG
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Backports
Related
related to SERVER-45646 If a filtering metadata refresh is sc... Closed
Backwards Compatibility: Fully Compatible
Operating System: ALL
Backport Requested:
v4.4, v4.2, v4.0
Sprint: Sharding EMEA 2021-07-26
Participants:

 Description   

The ShardServerCatalogCacheLoader doesn't interrupt ongoing operations on step up as opposed to on step down. This could lead us to a deadlock (with timeout): if a node is a secondary node at this point but afterwards it is elected as primary, it might end up issuing a _flushRoutingTableCacheUpdates against itself. This could lead us to a deadlock if the current refresh was coming from the RecoverRefreshThread: the issued _flushRoutingTableCacheUpdates comand will end up waiting until the current refresh is completed but the current refresh cannot be completed because it is waiting for the completion of the _flushRoutingTableCacheUpdates command.



 Comments   
Comment by Githook User [ 25/Jul/22 ]

Author:

{'name': 'Sergi Mateo Bellido', 'email': 'sergi.mateo-bellido@mongodb.com', 'username': 'smateo'}

Message: SERVER-58747 The ShardServerCatalogCacheLoader doesn't interrupt ongoing operations on step up

(cherry picked from commit 7a8df38d284e16a60884569a90ddfa07586d9ec0)
Branch: v4.2
https://github.com/mongodb/mongo/commit/4b16e0d00a54e18f7b6bcb2a999ebee6c1e49ea5

Comment by Githook User [ 25/Jul/22 ]

Author:

{'name': 'Sergi Mateo Bellido', 'email': 'sergi.mateo-bellido@mongodb.com', 'username': 'smateo'}

Message: SERVER-58747 The ShardServerCatalogCacheLoader doesn't interrupt ongoing operations on step up

(cherry picked from commit 7a8df38d284e16a60884569a90ddfa07586d9ec0)
Branch: v4.4
https://github.com/mongodb/mongo/commit/d028683784ae1377501d9b92f28c1be91f103af5

Comment by Vivian Ge (Inactive) [ 06/Oct/21 ]

Updating the fixversion since branching activities occurred yesterday. This ticket will be in rc0 when it’s been triggered. For more active release information, please keep an eye on #server-release. Thank you!

Comment by Githook User [ 23/Jul/21 ]

Author:

{'name': 'Sergi Mateo Bellido', 'email': 'sergi.mateo-bellido@mongodb.com', 'username': 'smateo'}

Message: SERVER-58747 The ShardServerCatalogCacheLoader doesn't interrupt ongoing operations on step up

(cherry picked from commit 7a8df38d284e16a60884569a90ddfa07586d9ec0)
Branch: v5.0
https://github.com/mongodb/mongo/commit/8c70142f2123724d6dc5042e7a0e1937597a6f76

Comment by Githook User [ 23/Jul/21 ]

Author:

{'name': 'Sergi Mateo Bellido', 'email': 'sergi.mateo-bellido@mongodb.com', 'username': 'smateo'}

Message: SERVER-58747 The ShardServerCatalogCacheLoader doesn't interrupt ongoing operations on step up
Branch: master
https://github.com/mongodb/mongo/commit/7a8df38d284e16a60884569a90ddfa07586d9ec0

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