diff options
author | Spencer T Brody <spencer@mongodb.com> | 2015-10-12 18:47:37 -0400 |
---|---|---|
committer | Spencer T Brody <spencer@mongodb.com> | 2015-10-13 23:27:06 -0400 |
commit | 110e24cb3571778f4abb53e8f121b14f529307f6 (patch) | |
tree | 988034cf220254503fdaafadb5f8abbe2f7ffc74 /src/mongo/db/write_concern_options.h | |
parent | 3c706c7fcabbb267a29c482b1c016e838ce82588 (diff) | |
download | mongo-110e24cb3571778f4abb53e8f121b14f529307f6.tar.gz |
SERVER-20891 User-initiated writes to the config server must use w:majority write concern
Diffstat (limited to 'src/mongo/db/write_concern_options.h')
-rw-r--r-- | src/mongo/db/write_concern_options.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/mongo/db/write_concern_options.h b/src/mongo/db/write_concern_options.h index a0cb45f8da9..1bac963f16f 100644 --- a/src/mongo/db/write_concern_options.h +++ b/src/mongo/db/write_concern_options.h @@ -87,6 +87,12 @@ public: */ bool shouldWaitForOtherNodes() const; + /** + * Returns true if this is a valid write concern to use against a config server. + * TODO(spencer): Once we stop supporting SCCC config servers, forbid this from allowing w:1 + */ + bool validForConfigServers() const; + void reset() { syncMode = NONE; wNumNodes = 0; |