-
Type:
Task
-
Resolution: Done
-
Priority:
Minor - P4
-
None
-
Affects Version/s: None
-
Component/s: None
-
None
-
Storage Engines - Server Integration
-
Fully Compatible
-
None
-
None
-
None
-
None
-
None
-
None
-
None
Overview
LogServerManager::_unhealthyServers is a secondary-only concept (it tracks log servers excluded from the candidate set when picking one to become standby), but it is currently stored as a member variable on LogServerManager. As a result it has to be defensively cleared from the primary path on every iteration of the new reconnect retry loop in becomePrimary.
Background
While reviewing the change to move primary reconnection inside LogServerManager::becomePrimary (which introduced an internal while (true) retry loop), a TODO was added in src/mongo/db/modules/atlas/src/disagg_storage/pali/log_server_manager.cpp noting this. The placeholder SERVER-XXXXX was used pending this ticket.
Scope of Work
- src/mongo/db/modules/atlas/src/disagg_storage/pali/log_server_manager.cpp — move _unhealthyServers ownership into the standby/secondary loop scope (e.g. a local in _standbyLoop, or a member of a secondary-only sub-object), and remove the _unhealthyServers.clear() call from the primary path.
- src/mongo/db/modules/atlas/src/disagg_storage/pali/log_server_manager.h — remove the member declaration if no longer needed at class scope.
- Replace the TODO(SERVER-XXXXX) comment with the issued ticket number, or delete it once the cleanup lands.
Acceptance Criteria
- _unhealthyServers is no longer a member of LogServerManager, or is otherwise scoped so the primary path cannot see it.
- The defensive _unhealthyServers.clear() call in becomePrimary is removed.
- Existing standby/secondary log-server selection behavior is preserved (the exclusion list still resets when appropriate on standby entry).
- The SERVER-XXXXX placeholder TODO is gone.
Technical Notes
- Producers: _standbyLoop (around lines 2727, 2742).
- Consumers: findLogServerToBecomeStandby (around lines 1632-1650) and the on-success clear at line 2645.
- No primary-side code reads _unhealthyServers; the clear in the new primary retry loop is purely defensive.