diff options
author | David Storch <david.storch@10gen.com> | 2018-08-30 18:53:07 -0400 |
---|---|---|
committer | David Storch <david.storch@10gen.com> | 2018-09-05 11:38:05 -0400 |
commit | fbf57dfc196c3e4d6b0313cadb71f10138b9c018 (patch) | |
tree | d55e3a143607b1e091f7ceaeb0dfcac799a11460 /src/mongo/db/storage | |
parent | 28cef55d81126b04732eaa41ff8b20e45636dde1 (diff) | |
download | mongo-fbf57dfc196c3e4d6b0313cadb71f10138b9c018.tar.gz |
SERVER-36156 Delete RecordFetcher.
Diffstat (limited to 'src/mongo/db/storage')
-rw-r--r-- | src/mongo/db/storage/record_fetcher.h | 57 | ||||
-rw-r--r-- | src/mongo/db/storage/record_store.h | 30 |
2 files changed, 0 insertions, 87 deletions
diff --git a/src/mongo/db/storage/record_fetcher.h b/src/mongo/db/storage/record_fetcher.h deleted file mode 100644 index 0c8d5f18080..00000000000 --- a/src/mongo/db/storage/record_fetcher.h +++ /dev/null @@ -1,57 +0,0 @@ -/** - * Copyright (C) 2014 MongoDB Inc. - * - * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Affero General Public License, version 3, - * as published by the Free Software Foundation. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU Affero General Public License for more details. - * - * You should have received a copy of the GNU Affero General Public License - * along with this program. If not, see <http://www.gnu.org/licenses/>. - * - * As a special exception, the copyright holders give permission to link the - * code of portions of this program with the OpenSSL library under certain - * conditions as described in each individual source file and distribute - * linked combinations including the program with the OpenSSL library. You - * must comply with the GNU Affero General Public License in all respects for - * all of the code used other than as permitted herein. If you modify file(s) - * with this exception, you may extend this exception to your version of the - * file(s), but you are not obligated to do so. If you do not wish to do so, - * delete this exception statement from your version. If you delete this - * exception statement from all source files in the program, then also delete - * it in the license file. - */ - -#pragma once - -namespace mongo { - -class OperationContext; - -/** - * Used for yielding while data is fetched from disk. - * - * @see RecordStore::recordNeedsFetch - */ -class RecordFetcher { -public: - virtual ~RecordFetcher() {} - - /** - * Performs any setup which is needed prior to yielding locks. - */ - virtual void setup(OperationContext* opCtx) = 0; - - /** - * Called after locks are yielded in order to bring data into memory. - * - * Should not be called more than once. - */ - virtual void fetch() = 0; -}; - -} // namespace mongo diff --git a/src/mongo/db/storage/record_store.h b/src/mongo/db/storage/record_store.h index 178574f43ab..308bab5992f 100644 --- a/src/mongo/db/storage/record_store.h +++ b/src/mongo/db/storage/record_store.h @@ -37,7 +37,6 @@ #include "mongo/db/exec/collection_scan_common.h" #include "mongo/db/record_id.h" #include "mongo/db/storage/record_data.h" -#include "mongo/db/storage/record_fetcher.h" namespace mongo { @@ -48,7 +47,6 @@ struct CompactStats; class MAdvise; class NamespaceDetails; class OperationContext; -class RecordFetcher; class RecordStoreCompactAdaptor; class RecordStore; @@ -183,27 +181,6 @@ public: * "saved" state, so callers must still call restoreState to use this object. */ virtual void reattachToOperationContext(OperationContext* opCtx) = 0; - - // - // RecordFetchers - // - // Storage engines which do not support document-level locking hold locks at collection or - // database granularity. As an optimization, these locks can be yielded when a record needs - // to be fetched from secondary storage. If this method returns non-NULL, then it indicates - // that the query system layer should yield its locks, following the protocol defined by the - // RecordFetcher class, so that a potential page fault is triggered out of the lock. - // - // Storage engines which support document-level locking need not implement this. - // - // TODO see if these can be replaced by WriteConflictException. - // - - /** - * Returns a RecordFetcher if needed for a call to next() or none if unneeded. - */ - virtual std::unique_ptr<RecordFetcher> fetcherForNext() const { - return {}; - } }; /** @@ -238,13 +215,6 @@ public: virtual void saveUnpositioned() { save(); } - - /** - * Returns a RecordFetcher if needed to fetch the provided Record or none if unneeded. - */ - virtual std::unique_ptr<RecordFetcher> fetcherForId(const RecordId& id) const { - return {}; - } }; /** |