summaryrefslogtreecommitdiff
path: root/src/mongo/db/namespace_string.cpp
diff options
context:
space:
mode:
authorRishab Joshi <rishab.joshi@mongodb.com>2022-05-27 21:58:26 +0000
committerEvergreen Agent <no-reply@evergreen.mongodb.com>2022-05-27 23:08:01 +0000
commit1a5a5419426d512a8648914206776025beb496c4 (patch)
tree8f65a254a3c926651d761d24d0749c6377bf63a7 /src/mongo/db/namespace_string.cpp
parent450f4b6516f29e6cf8545145932b8ae6138701cc (diff)
downloadmongo-1a5a5419426d512a8648914206776025beb496c4.tar.gz
SERVER-66123 Introduce logic to write to the change collection in the primary.
Diffstat (limited to 'src/mongo/db/namespace_string.cpp')
-rw-r--r--src/mongo/db/namespace_string.cpp9
1 files changed, 4 insertions, 5 deletions
diff --git a/src/mongo/db/namespace_string.cpp b/src/mongo/db/namespace_string.cpp
index 525dd9c6724..d16370da310 100644
--- a/src/mongo/db/namespace_string.cpp
+++ b/src/mongo/db/namespace_string.cpp
@@ -243,7 +243,7 @@ bool NamespaceString::isLegalClientSystemNS(
return true;
}
- if (isChangeStreamChangeCollection()) {
+ if (isChangeCollection()) {
return true;
}
@@ -404,8 +404,8 @@ bool NamespaceString::isChangeStreamPreImagesCollection() const {
return ns() == kChangeStreamPreImagesNamespace.ns();
}
-bool NamespaceString::isChangeStreamChangeCollection() const {
- return db() == kConfigDb && coll() == kChangeStreamChangeCollection;
+bool NamespaceString::isChangeCollection() const {
+ return db() == kConfigDb && coll() == kChangeCollectionName;
}
bool NamespaceString::isConfigImagesCollection() const {
@@ -432,8 +432,7 @@ NamespaceString NamespaceString::getTimeseriesViewNamespace() const {
}
bool NamespaceString::isImplicitlyReplicated() const {
- if (isChangeStreamPreImagesCollection() || isConfigImagesCollection() || isChangeCollection() ||
- isChangeStreamChangeCollection()) {
+ if (isChangeStreamPreImagesCollection() || isConfigImagesCollection() || isChangeCollection()) {
// Implicitly replicated namespaces are replicated, although they only replicate a subset of
// writes.
invariant(isReplicated());