[SERVER-10266] Support GLE with w:majority in master/slave Created: 19/Jul/13  Updated: 08/Apr/14  Resolved: 03/Dec/13

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

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

Issue Links:
Depends
is depended on by DOCS-1926 Document : Support GLE with w:majorit... Closed
is depended on by SERVER-12072 Stop swallowing "norepl" errors in th... Closed
Related
related to SERVER-10250 validate_user_documents.js failed on ... Closed
is related to SERVER-11669 Swallow "norepl" errors in the shell ... Closed
is related to SERVER-11733 Add a writeConcern mode that works on... Closed
is related to SERVER-11959 Support GLE with w:majority on config... Closed
Backwards Compatibility: Fully Compatible
Participants:

 Description   

Currently if you run GLE with w:majority on a master/slave setup you get the error "noreplset". We should pick a good definition for what w:majority means on a master/slave setup and make that work.



 Comments   
Comment by Eric Milkie [ 03/Dec/13 ]

Decided, we're going to treat w:majority as w:1 in master/slave.

Comment by Tad Marshall [ 20/Jul/13 ]

The above commit broke jstests/sharding/auth.js on all platforms:
http://buildbot.mongodb.org/builders/Nightly%20OS%20X%2010.5%2064-bit/builds/1377/steps/test/logs/stdio
http://buildlogs.mongodb.org/Nightly%20OS%20X%2010.5%2064-bit/builds/1377/test/recent%20failures/auth.js

Sat Jul 20 00:01:37.678 couldn't add user: norepl at src/mongo/shell/db.js:169
failed to load: /data/buildslaves/OS_X_105_64bit_Nightly/mongo/jstests/sharding/auth.js

Comment by auto [ 20/Jul/13 ]

Author:

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

Message: Revert "SERVER-10266 Remove no longer necessary special case of norepl errors from addUser shell helper"

This reverts commit 2f3bb8c8550a798c7388313273fe8c71e94dc552.
Branch: master
https://github.com/mongodb/mongo/commit/9bf70757db09b3a7166440c508bf798d50bd212a

Comment by auto [ 19/Jul/13 ]

Author:

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

Message: SERVER-10266 Remove no longer necessary special case of norepl errors from addUser shell helper
Branch: master
https://github.com/mongodb/mongo/commit/2f3bb8c8550a798c7388313273fe8c71e94dc552

Comment by auto [ 19/Jul/13 ]

Author:

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

Message: SERVER-10266 Make GLE with w:majority succeed on master/slave
Branch: master
https://github.com/mongodb/mongo/commit/dc70e61fc3300bb5f4f27d6f1c2a0cb7669c4fbc

Comment by Scott Hernandez (Inactive) [ 19/Jul/13 ]

Yep, that is exactly what I was going to suggest as well; a little confusing but there are technical limitations with master/slave.

Comment by Eric Milkie [ 19/Jul/13 ]

This is in the spirit of making w:majority work on single nodes – it doesn't return an error, for the convenience of development.

Comment by Spencer Brody (Inactive) [ 19/Jul/13 ]

After talking with milkie, we decided that GLE with w:majority will behave the same as w:1 (it will not wait for any replication) but will return successfully with a wnote warning that majority isn't supported on master/slave.

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