0

All,

Lets say devoper sets the write concern as Majority in MongoDB

As a DBA can i have the access to change the write concern of whole cluster or only the developers has the rights to do through coding ?

In replica sets we can do the change through conf settings but i beleive it wouldn't override the default one

0

Write concern can be set differently for every DML operation and that overrides the default write concern value. So, if default value is majority, developer can choose w:0 or even w:all for update operation, if he or she wants to do so.

  • how to set the default write concern for all CRUD operations ? as a DBA can i have the rights to change that – vignesh Jul 12 '18 at 7:58
  • Check docs.mongodb.com/manual/core/replica-set-write-concern under "Modify Default Write Concern" – JJussi Jul 12 '18 at 17:40
  • yes i read, but it says it cannot override the default write concern, My question is can the DBA change the deafult write concern ? – vignesh Jul 13 '18 at 7:53
  • That is "the default write concern"! And as it says "If you issue a write operation with a specific write concern, the write operation uses its own write concern instead of the default." you can override this default write concern. That means that you define (f.ex. at update operation) you own write concern what overrides this default what you have defined at replica set configuration. But other round, if developer defines his/her own write concern, you as DBA cannot override THAT. – JJussi Jul 13 '18 at 11:37

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.