[SERVER-36128] ReplicationCoordinatorImpl::fillIsMasterForReplSet should return isMaster:false while in shutdown Created: 13/Jul/18  Updated: 29/Oct/23  Resolved: 08/Aug/18

Status: Closed
Project: Core Server
Component/s: Replication
Affects Version/s: None
Fix Version/s: 3.6.8, 4.0.2, 4.1.2

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

Issue Links:
Backports
Depends
is depended on by SERVER-34666 Reduce the number of retries needed f... Backlog
Backwards Compatibility: Fully Compatible
Operating System: ALL
Backport Requested:
v4.0, v3.6
Sprint: Repl 2018-08-13
Participants:
Linked BF Score: 16

 Description   

Clients use the isMaster field here to determine whether or not to direct writes to the node. When we're technically "master" but we can't accept writes (i.e. when in drain mode), we claim not to be master. We should do the same while shutting down.

This affects retryable writes, in that a write interrupted due to shutdown may immediately re-try on the same node if it still claims to be master.



 Comments   
Comment by Githook User [ 27/Aug/18 ]

Author:

{'name': 'Spencer T Brody', 'email': 'spencer@mongodb.com', 'username': 'stbrody'}

Message: SERVER-36128 Don't return ismaster:true while in shutdown

(cherry picked from commit 08f41abf93060ab4e62797933deba77860132c18)
Branch: v3.6
https://github.com/mongodb/mongo/commit/f2abc60e49f3f752f573fae8283baed673189a82

Comment by Githook User [ 16/Aug/18 ]

Author:

{'username': 'stbrody', 'email': 'spencer@mongodb.com', 'name': 'Spencer T Brody'}

Message: SERVER-36128 Don't return ismaster:true while in shutdown

(cherry picked from commit 08f41abf93060ab4e62797933deba77860132c18)
Branch: v4.0
https://github.com/mongodb/mongo/commit/4d416e3335174373b7fb1ed3f98600d056da8d6e

Comment by Githook User [ 08/Aug/18 ]

Author:

{'name': 'Spencer T Brody', 'email': 'spencer@mongodb.com', 'username': 'stbrody'}

Message: SERVER-36128 Don't return ismaster:true while in shutdown
Branch: master
https://github.com/mongodb/mongo/commit/08f41abf93060ab4e62797933deba77860132c18

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