diff options
author | Rishab Joshi <rishab.joshi@mongodb.com> | 2022-08-11 17:00:55 +0000 |
---|---|---|
committer | Evergreen Agent <no-reply@evergreen.mongodb.com> | 2022-08-11 18:34:34 +0000 |
commit | 7be22a4e693ed231f217c7670de076dc1960b238 (patch) | |
tree | 5e1b3e5901dd9f05e09cf85a6061d4aa3c3f34a9 /src/mongo/db/change_stream_pre_images_collection_manager.h | |
parent | f387fa8cc75b9129fb1d57d302ed424349990d5e (diff) | |
download | mongo-7be22a4e693ed231f217c7670de076dc1960b238.tar.gz |
SERVER-66631 Implement command to enable and disable the change stream.
Diffstat (limited to 'src/mongo/db/change_stream_pre_images_collection_manager.h')
-rw-r--r-- | src/mongo/db/change_stream_pre_images_collection_manager.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/mongo/db/change_stream_pre_images_collection_manager.h b/src/mongo/db/change_stream_pre_images_collection_manager.h index 75efb28c22d..dede0e38c96 100644 --- a/src/mongo/db/change_stream_pre_images_collection_manager.h +++ b/src/mongo/db/change_stream_pre_images_collection_manager.h @@ -89,6 +89,13 @@ public: const ChangeStreamPreImage& preImage); /** + * Returns true if the pre-images collection exists, false otherwise. If 'tenantId' is provided + * then the pre-images collection associated with that tenant will be checked for existence, + * otherwise the default pre-images collection will be checked. + */ + static bool hasPreImagesCollection(OperationContext* opCtx, boost::optional<TenantId> tenantId); + + /** * Scans the system pre-images collection and deletes the expired pre-images from it. */ static void performExpiredChangeStreamPreImagesRemovalPass(Client* client); |