summaryrefslogtreecommitdiff
path: root/src/mongo/db/repair_database.cpp
diff options
context:
space:
mode:
authorMathias Stearn <mathias@10gen.com>2015-04-29 19:47:42 -0400
committerMathias Stearn <mathias@10gen.com>2015-05-08 14:27:27 -0400
commitc5f317f59e41caffcd3972bc741abaa649229a5b (patch)
treeff30f65ab46d8cfbe9f4ff81d6a82fec0ad43b86 /src/mongo/db/repair_database.cpp
parent849b8f436a5178c5be6afc2a49e9a4d1ecf5d92b (diff)
downloadmongo-c5f317f59e41caffcd3972bc741abaa649229a5b.tar.gz
SERVER-18227 Add a mechanism to disable document validation and start using it
This does not necessarily cover all places that need to disable validation.
Diffstat (limited to 'src/mongo/db/repair_database.cpp')
-rw-r--r--src/mongo/db/repair_database.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/mongo/db/repair_database.cpp b/src/mongo/db/repair_database.cpp
index 516827a3715..9bbb8da24de 100644
--- a/src/mongo/db/repair_database.cpp
+++ b/src/mongo/db/repair_database.cpp
@@ -43,6 +43,7 @@
#include "mongo/db/catalog/database.h"
#include "mongo/db/catalog/database_catalog_entry.h"
#include "mongo/db/catalog/database_holder.h"
+#include "mongo/db/catalog/document_validation.h"
#include "mongo/db/catalog/index_create.h"
#include "mongo/db/catalog/index_key_validate.h"
#include "mongo/db/storage/mmap_v1/mmap_v1_engine.h"
@@ -176,7 +177,7 @@ namespace {
bool preserveClonedFilesOnFailure,
bool backupOriginalFiles) {
-
+ DisableDocumentValidation validationDisabler(txn);
// We must hold some form of lock here
invariant(txn->lockState()->isLocked());