[DOCS-9790] Clarify how the majority is calculate for w:majority Created: 19/Jan/17  Updated: 27/Oct/23  Resolved: 07/Jun/18

Status: Closed
Project: Documentation
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Improvement Priority: Major - P3
Reporter: Linda Qin Assignee: Kay Kim (Inactive)
Resolution: Works as Designed Votes: 1
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Participants:
Days since reply: 6 years, 39 weeks, 2 days ago

 Description   

This is for the document write concern majority:

Requests acknowledgment that write operations have propagated to the majority of voting nodes [2], including the primary.

Currently we only mention that "majority" is calculated by the majority of voting nodes. However, this doesn't cover the scenario when the majority of voting nodes are arbiters, like Primary-Arbiter-Arbiter (thought this is not a recommended deployment).

It would be nice to clarify that it calculated by the majority of voting nodes or all non-arbiter voting nodes if the majority of voting nodes are arbiters. all non-arbiter voting nodes if at least half of voting nodes are arbiters.

https://github.com/mongodb/mongo/blob/master/src/mongo/db/repl/replica_set_config.cpp#L688-L699

Edit: updated "all non-arbiter voting nodes if the majority of voting nodes are arbiters." to "all non-arbiter voting nodes if at least half of voting nodes are arbiters"



 Comments   
Comment by Eric Sommer [ 15/May/17 ]

Updated link: https://github.com/mongodb/mongo/blob/49140247ca85644438e7394b6950f7687fbd4c91/src/mongo/db/repl/repl_set_config.cpp#L690-L696

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