[SERVER-23133] replSetMaintenance should not fail if the node is in candidate state Created: 14/Mar/16  Updated: 06/Dec/22

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

Type: Improvement Priority: Minor - P4
Reporter: Eric Milkie Assignee: Backlog - Replication Team
Resolution: Unresolved Votes: 0
Labels: neweng
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Related
Assigned Teams:
Replication
Participants:
Linked BF Score: 0

 Description   

If you run the replSetMaintenance command on a SECONDARY that is currently running an election, you get an error:

{ "ok" : 0, "errmsg" : "currently running for election", "code" : 95 }

This is not ideal, and makes the command hard to use in a script. Instead, the behavior should be that the election is cancelled and the node enters maintenance mode successfully.


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