-
Type: Improvement
-
Resolution: Won't Fix
-
Priority: Major - P3
-
None
-
Affects Version/s: None
-
Component/s: Testing Infrastructure
-
Server Tooling & Methods
ReplSetTest can initiate and startup a replica set, but if the number of nodes in the set is greater than the number of voting nodes (currently 7), it will fail. It would be good if one could specify a value for nodes larger than the voting limit, and have replSetTest set the extra nodes to votes to 0 and priority to 0.
The current workaround is as follows:
var nodeNum = 15; var votingLimit = 7; var rs = new ReplSetTest({nodes: nodeNum}); rs.startSet(); rsConfig = rs.getReplSetConfig(); for (var i = votingLimit; i < nodeNum; i++) { rsConfig.members[i].votes = 0; rsConfig.members[i].priority = 0; } rs.initiate(rsConfig);