[SERVER-49159] Return NotPrimaryOrSecondary if currentTime is uninitialized in waitForReadConcernImpl Created: 29/Jun/20 Updated: 29/Oct/23 Resolved: 25/Sep/20 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Replication |
| Affects Version/s: | None |
| Fix Version/s: | 4.8.0, 4.4.3 |
| Type: | Bug | Priority: | Major - P3 |
| Reporter: | Vesselina Ratcheva (Inactive) | Assignee: | Xuerui Fa |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||||||||||||||
| Backwards Compatibility: | Fully Compatible | ||||||||||||||||||||
| Operating System: | ALL | ||||||||||||||||||||
| Backport Requested: |
v4.4
|
||||||||||||||||||||
| Sprint: | Repl 2020-07-27, Repl 2020-09-21, Repl 2020-10-05 | ||||||||||||||||||||
| Participants: | |||||||||||||||||||||
| Linked BF Score: | 9 | ||||||||||||||||||||
| Description |
|
Initial sync is currently resumable after certain transient failures, including brief outages due to sync source restart. When a sync source goes down and back up again, we generally expect that to be observed as a network error. However, there is a specific window in which attempts against such a freshly restarted sync source can error in a way that is fatal to the initial sync process. It is possible for the oplog fetcher to try to read from the remote oplog while that node is still in STARTUP state and is at (0,0) appliedThrough and clusterTime; in such a scenario the read will fail as the sync source is unable to satisfy the afterClusterTime (0,1) read (this error happens on a request validation level). Since this is not a network error, we will not use the new oplog fetcher restart strategy and instead fall back to the old behavior, which is to retry n (default 10) times. If those retries are exhausted, then initial sync fails. |
| Comments |
| Comment by Githook User [ 30/Nov/20 ] |
|
Author: {'name': 'XueruiFa', 'email': 'xuerui.fa@mongodb.com', 'username': 'XueruiFa'}Message: (cherry picked from commit 9492de5aac55c8c579044dfa54703056d6012d95) |
| Comment by Githook User [ 25/Sep/20 ] |
|
Author: {'name': 'XueruiFa', 'email': 'xuerui.fa@mongodb.com', 'username': 'XueruiFa'}Message: |
| Comment by Judah Schvimer [ 29/Jun/20 ] |
|
Would a node retry if it received a "NotMasterOrSecondary" error upon querying a node in STARTUP? Making that error code come first seems like one solution. |