summaryrefslogtreecommitdiff
path: root/jstests/concurrency
diff options
context:
space:
mode:
authorGregory Noma <gregory.noma@gmail.com>2020-04-28 09:45:47 -0400
committerEvergreen Agent <no-reply@evergreen.mongodb.com>2020-04-28 13:58:40 +0000
commitf4800dd5dea55597b8984e547771aee5282f0386 (patch)
treebf9a7132e8a7a8c601e9fe6406e1139f77a3ca5e /jstests/concurrency
parentaa2e0ee6d817951a29f2fec33d374d13d8f46802 (diff)
downloadmongo-f4800dd5dea55597b8984e547771aee5282f0386.tar.gz
SERVER-47632 Explicitly ignore all acceptable moveChunk errors in update shard key concurrency workload
Diffstat (limited to 'jstests/concurrency')
-rw-r--r--jstests/concurrency/fsm_workloads/random_moveChunk_update_shard_key.js11
1 files changed, 9 insertions, 2 deletions
diff --git a/jstests/concurrency/fsm_workloads/random_moveChunk_update_shard_key.js b/jstests/concurrency/fsm_workloads/random_moveChunk_update_shard_key.js
index 30d33f6f188..c034b8d06dc 100644
--- a/jstests/concurrency/fsm_workloads/random_moveChunk_update_shard_key.js
+++ b/jstests/concurrency/fsm_workloads/random_moveChunk_update_shard_key.js
@@ -29,8 +29,15 @@ var $config = extendWorkload($config, function($config, $super) {
// identified by the failed migration's error message.
$config.data.isMoveChunkErrorAcceptable = (err) => {
return err.message &&
- (err.message.indexOf("CommandFailed") > -1 ||
- err.message.indexOf("Documents in target range may still be in use"));
+ (err.message.includes("CommandFailed") ||
+ err.message.includes("Documents in target range may still be in use") ||
+ // This error can occur when the test updates the shard key value of a document whose
+ // chunk has been moved to another shard. Receiving a chunk only waits for documents
+ // with shard key values in that range to have been cleaned up by the range deleter.
+ // So, if the range deleter has not yet cleaned up that document when the chunk is
+ // moved back to the original shard, the moveChunk may fail as a result of a duplicate
+ // key error on the recipient.
+ err.message.includes("Location51008"));
};
$config.data.runningWithStepdowns =