diff options
author | Jason Chan <jason.chan@mongodb.com> | 2022-01-05 16:54:57 +0000 |
---|---|---|
committer | Evergreen Agent <no-reply@evergreen.mongodb.com> | 2022-01-21 22:36:25 +0000 |
commit | 5aa944a184afa23481a5db2c53f9de8e7d9ce326 (patch) | |
tree | 0cfe82b92d988f56c39125c8dab62e83582835a4 | |
parent | 8334f1357e54586bf70a466cf2694674cfa54206 (diff) | |
download | mongo-5aa944a184afa23481a5db2c53f9de8e7d9ce326.tar.gz |
SERVER-61923 Fix bug where consistency checker can mask error due to ignoring inconsistency in image collections
(cherry picked from commit e2d48665f771a82bfe7de2a112276cd3692a6007)
-rw-r--r-- | src/mongo/shell/data_consistency_checker.js | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/mongo/shell/data_consistency_checker.js b/src/mongo/shell/data_consistency_checker.js index 3edfd56a663..d91c93ebaae 100644 --- a/src/mongo/shell/data_consistency_checker.js +++ b/src/mongo/shell/data_consistency_checker.js @@ -335,7 +335,13 @@ var {DataConsistencyChecker} = (function() { collectionPrinted, sourceCollInfos, syncingCollInfos, collName); const shouldIgnoreFailure = this.canIgnoreCollectionDiff(sourceCollInfos, syncingCollInfos, collName); - success = shouldIgnoreFailure; + if (shouldIgnoreFailure) { + prettyPrint( + `Collection diff in ${dbName}.${collName} can be ignored: ${dbHashesMsg} + . Inconsistencies in the image collection can be expected in certain + restart scenarios.`); + } + success = shouldIgnoreFailure && success; } }); |