[SERVER-29837] TopologyCoordinator::shouldChangeSyncSource() should consider chainingAllowed setting when comparing sync source's optime against secondaries Created: 23/Jun/17  Updated: 06/Dec/22

Status: Backlog
Project: Core Server
Component/s: Replication
Affects Version/s: None
Fix Version/s: None

Type: Improvement Priority: Major - P3
Reporter: Benety Goh Assignee: Backlog - Replication Team
Resolution: Unresolved Votes: 0
Labels: neweng
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Duplicate
is duplicated by SERVER-36775 Replication sync issue Closed
Related
Assigned Teams:
Replication
Backwards Compatibility: Fully Compatible
Participants:
Case:

 Description   

A secondary node will discard its current sync source if its sync source appears to lag another node by more than a certain threshold (See server parameter maxSyncSourceLagSecs) and log the following message:

re-evaluating sync source because our current sync source's most recent  OpTime is XXXXX  which is more than NNN behind member XXXX  whose most recent OpTime is XXXX

If chaining is disallowed in the replica set configuration, the secondary will choose the same node (the primary) that it just discarded as a sync source earlier.

The criteria for deciding to change sync source should be improved to consider the current chainingAllowed setting to reduce the frequency of reconnecting to the same (primary) sync source to query the oplog.

https://docs.mongodb.com/manual/reference/replica-configuration/#rsconf.settings.chainingAllowed


Generated at Thu Feb 08 04:21:56 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.