diff options
author | Daniel Gottlieb <daniel.gottlieb@10gen.com> | 2017-02-26 12:01:02 -0500 |
---|---|---|
committer | Daniel Gottlieb <daniel.gottlieb@10gen.com> | 2017-02-26 12:01:02 -0500 |
commit | b94dd91adb6d8859ab5e5f91731be2e8571eed0c (patch) | |
tree | ef3116315d0f79c9e4f690fffc5bdabb93f4751c /src/mongo/db/storage/mmap_v1/catalog/namespace_index.h | |
parent | ce23378926659bc50604032782485c2f962c37ac (diff) | |
download | mongo-b94dd91adb6d8859ab5e5f91731be2e8571eed0c.tar.gz |
revert "SERVER-18410: Replace RWLock with OperationContext/LockManager"
This reverts commit 9c9bbf3318113cfdd4d9b72f493b6ebd23f1837e.
Diffstat (limited to 'src/mongo/db/storage/mmap_v1/catalog/namespace_index.h')
-rw-r--r-- | src/mongo/db/storage/mmap_v1/catalog/namespace_index.h | 12 |
1 files changed, 2 insertions, 10 deletions
diff --git a/src/mongo/db/storage/mmap_v1/catalog/namespace_index.h b/src/mongo/db/storage/mmap_v1/catalog/namespace_index.h index 51aae08ea61..8bcf836518c 100644 --- a/src/mongo/db/storage/mmap_v1/catalog/namespace_index.h +++ b/src/mongo/db/storage/mmap_v1/catalog/namespace_index.h @@ -51,17 +51,9 @@ class NamespaceIndex { MONGO_DISALLOW_COPYING(NamespaceIndex); public: - NamespaceIndex(OperationContext* txn, const std::string& dir, const std::string& database); + NamespaceIndex(const std::string& dir, const std::string& database); ~NamespaceIndex(); - /** - * Must be called before destruction. - */ - void close(OperationContext* txn) { - LockMongoFilesExclusive lock(txn); - _f.close(txn); - } - /* returns true if the file represented by this file exists on disk */ bool pathExists() const; @@ -94,7 +86,7 @@ private: const std::string _dir; const std::string _database; - DurableMappedFile _f; + DurableMappedFile _f{MongoFile::Options::SEQUENTIAL}; std::unique_ptr<NamespaceHashTable> _ht; }; } |