diff options
author | Esha Maharishi <esha.maharishi@mongodb.com> | 2018-02-05 16:05:52 -0500 |
---|---|---|
committer | Esha Maharishi <esha.maharishi@mongodb.com> | 2018-02-05 17:25:17 -0500 |
commit | 481e017d1d4fbe3468292c952ee0ba4ce31a92e9 (patch) | |
tree | 09d85c28ab36609facc5c3c2e757b724deb7d795 /src/mongo/s/catalog_cache.h | |
parent | e747312da666720700f4207a81a927c1b93c36dc (diff) | |
download | mongo-481e017d1d4fbe3468292c952ee0ba4ce31a92e9.tar.gz |
SERVER-33022 make the CatalogCache cache the databaseVersion in the DatabaseInfoEntry
Diffstat (limited to 'src/mongo/s/catalog_cache.h')
-rw-r--r-- | src/mongo/s/catalog_cache.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/mongo/s/catalog_cache.h b/src/mongo/s/catalog_cache.h index aeeae8cb25e..b4b93eced47 100644 --- a/src/mongo/s/catalog_cache.h +++ b/src/mongo/s/catalog_cache.h @@ -34,6 +34,7 @@ #include "mongo/s/catalog_cache_loader.h" #include "mongo/s/chunk_manager.h" #include "mongo/s/client/shard.h" +#include "mongo/s/database_version_gen.h" #include "mongo/stdx/memory.h" #include "mongo/stdx/mutex.h" #include "mongo/util/concurrency/notification.h" @@ -171,6 +172,9 @@ private: bool shardingEnabled; StringMap<CollectionRoutingInfoEntry> collections; + + // Optional while featureCompatibilityVersion 3.6 is supported. + boost::optional<DatabaseVersion> databaseVersion; }; using DatabaseInfoMap = StringMap<std::shared_ptr<DatabaseInfoEntry>>; @@ -245,6 +249,8 @@ public: bool shardingEnabled() const; + boost::optional<DatabaseVersion> databaseVersion() const; + private: friend class CatalogCache; |