|
The CRUD specification has added parameters to many of the options classes called bypassDocumentValidation. The following classes have been updated:
- AggregateOptions: only for $out
- InsertOneOptions: This is a new class, now with a single field.
- InsertManyOptions
- UpdateOptions
- BulkWriteOptions
- FindOneAndReplaceOptions
- FindOneAndUpdateOptions
Using the new option requires the BypassDocumentValidation permission which is granted to the built-in roles 'restore' and 'dbadmin'. Other commands that have been updated, but not specified in the CRUD spec are:
- applyOps
- clone
- cloneCollection
- copyDb
- mapReduce
Implementation for Unacknowledged Writes
If your driver sends unacknowledged writes using op codes (OP_INSERT, OP_UPDATE, OP_DELETE), you MUST raise an error when bypassDocumentValidation is explicitly set (true or false) by a user on >= 3.2 servers.
|