diff options
author | Vishnu Kaushik <vishnu.kaushik@mongodb.com> | 2021-01-28 19:53:03 +0000 |
---|---|---|
committer | Evergreen Agent <no-reply@evergreen.mongodb.com> | 2021-02-01 23:11:42 +0000 |
commit | 9742a9c5d377098e0d71bff1547e5b14f37caec5 (patch) | |
tree | 93a37af6b6d5876de98ddb0975f7ee43bf8dc208 /jstests | |
parent | ca2d817f0a7dc8cad500a7b2e304400c65243217 (diff) | |
download | mongo-9742a9c5d377098e0d71bff1547e5b14f37caec5.tar.gz |
SERVER-53126 Drop oplog buffer collection once the migration is garbage collected on recipient side.
Diffstat (limited to 'jstests')
-rw-r--r-- | jstests/replsets/libs/tenant_migration_test.js | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/jstests/replsets/libs/tenant_migration_test.js b/jstests/replsets/libs/tenant_migration_test.js index 84057636cc7..a810a8c889a 100644 --- a/jstests/replsets/libs/tenant_migration_test.js +++ b/jstests/replsets/libs/tenant_migration_test.js @@ -281,7 +281,8 @@ function TenantMigrationTest( cmdObj, this.getDonorRst(), retryOnRetryableErrors); // If the command succeeded, we expect that the migration is marked garbage collectable on - // the donor and the recipient. Check the state docs for expireAt. + // the donor and the recipient. Check the state docs for expireAt, and check that the oplog + // buffer collection has been dropped. if (res.ok) { const donorPrimary = this.getDonorPrimary(); const recipientPrimary = this.getRecipientPrimary(); @@ -301,6 +302,10 @@ function TenantMigrationTest( if (recipientStateDoc) { assert(recipientStateDoc.expireAt); } + + const configDBCollections = recipientPrimary.getDB('config').getCollectionNames(); + assert(!configDBCollections.includes('repl.migration.oplog_' + migrationIdString), + configDBCollections); } return res; |