-
Type: Bug
-
Resolution: Fixed
-
Priority: Major - P3
-
Affects Version/s: None
-
Component/s: Monitoring
-
None
When application operations fail with network errors or not master errors, we reset the server to Unknown according to the rules in SDAM Error Handling section. However pymongo does not publish any ServerDescriptionChangedEvent or TopologyDescriptionChangedEvent:
https://github.com/mongodb/mongo-python-driver/blob/3.10.1/pymongo/topology.py#L552-L554
def _reset_server(self, address, reset_pool): ... # Mark this server Unknown. self._description = self._description.reset_server(address) self._update_servers()
We should mark the server unknown like this:
def _reset_server(self, address, reset_pool): ... # Mark this server Unknown. unknown_sd = ServerDescription(address) self._process_change(unknown_sd)
_process_change automatically handles the event publishing.
- related to
-
PYTHON-2108 POC : Reduce Client Time To Recovery On Topology Changes
- Closed