[SERVER-39212] waitForSecondaries in background dbhash check must wait for lastApplied to reach clusterTime when enableMajorityReadConcern=false Created: 25/Jan/19  Updated: 29/Oct/23  Resolved: 29/Jan/19

Status: Closed
Project: Core Server
Component/s: Replication, Testing Infrastructure
Affects Version/s: None
Fix Version/s: 4.0.7, 4.1.8

Type: Bug Priority: Major - P3
Reporter: Tess Avitabile (Inactive) Assignee: Tess Avitabile (Inactive)
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Backports
Depends
Backwards Compatibility: Fully Compatible
Operating System: ALL
Backport Requested:
v4.0
Sprint: Repl 2019-02-11
Participants:
Linked BF Score: 16

 Description   

The waitForSecondaries function in the background dbhash check waits for theĀ lastCommittedOpTime on the secondary to reach the clusterTime when enableMajorityReadConcern=false. However, the lastCommittedOpTime is the secondary's knowledge of the majority commit point and may be behind its last applied. For the atClusterTime wait for readConcern to succeed on master, the secondary's lastApplied must be at least clusterTime, so we should check replSetGetStatus.optimes.appliedOpTime. For the atClusterTime wait for readConcern to succeed on 4.0, the secondary's current committed snapshot must be at least clusterTime, so we should check replSetGetStatus.optimes.readConcernMajorityOpTime. Note that readConcernMajorityOpTime may be ahead of appliedOpTime on master.



 Comments   
Comment by Githook User [ 05/Feb/19 ]

Author:

{'name': 'Tess Avitabile', 'email': 'tess.avitabile@mongodb.com', 'username': 'tessavitabile'}

Message: SERVER-39212 waitForSecondaries in background dbhash check must wait for lastApplied to reach clusterTime when enableMajorityReadConcern=false
Branch: v4.0
https://github.com/mongodb/mongo/commit/8ce14201224d3c04fd7a2401f64270f73d2652df

Comment by Githook User [ 30/Jan/19 ]

Author:

{'email': 'tess.avitabile@mongodb.com', 'name': 'Tess Avitabile'}

Message: SERVER-39212 waitForSecondaries in background dbhash check must wait for lastApplied to reach clusterTime when enableMajorityReadConcern=false
Branch: master
https://github.com/mongodb/mongo/commit/b4ee2a119c65d1f2a0cb2288c1242fbf4f74a543

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