summaryrefslogtreecommitdiff
path: root/src/mongo/db/storage/snapshot_manager.h
diff options
context:
space:
mode:
authorEric Milkie <milkie@10gen.com>2018-02-21 15:24:03 -0500
committerEric Milkie <milkie@10gen.com>2018-03-05 07:49:48 -0500
commit8257a817bfaf596e68204ad858f811e294d986b5 (patch)
tree2af6c44d80b7cdc93b8321b25d1cbef9ea1f1a89 /src/mongo/db/storage/snapshot_manager.h
parent1cf874bd73ebb13f753840bb6eea63207076c438 (diff)
downloadmongo-8257a817bfaf596e68204ad858f811e294d986b5.tar.gz
SERVER-33318 simplify oldest_timestamp setting
Diffstat (limited to 'src/mongo/db/storage/snapshot_manager.h')
-rw-r--r--src/mongo/db/storage/snapshot_manager.h25
1 files changed, 1 insertions, 24 deletions
diff --git a/src/mongo/db/storage/snapshot_manager.h b/src/mongo/db/storage/snapshot_manager.h
index 0577236a4ce..4c1def141af 100644
--- a/src/mongo/db/storage/snapshot_manager.h
+++ b/src/mongo/db/storage/snapshot_manager.h
@@ -38,8 +38,6 @@
namespace mongo {
-class RecoveryUnit;
-
/**
* Manages snapshots that can be read from at a later time.
*
@@ -49,38 +47,17 @@ class RecoveryUnit;
class SnapshotManager {
public:
/**
- * Prepares the passed-in OperationContext for snapshot creation.
- *
- * The passed-in OperationContext will be associated with a point-in-time that can be used
- * for creating a snapshot later.
- *
- * This must be the first method called after starting a ScopedTransaction, and it is
- * illegal to start a WriteUnitOfWork inside of the same ScopedTransaction.
- */
- virtual Status prepareForCreateSnapshot(OperationContext* opCtx) = 0;
-
- /**
* Sets the snapshot to be used for committed reads.
*
* Implementations are allowed to assume that all older snapshots have names that compare
* less than the passed in name, and newer ones compare greater.
*
* This is called while holding a very hot mutex. Therefore it should avoid doing any work that
- * can be done later. In particular, cleaning up of old snapshots should be deferred until
- * cleanupUnneededSnapshots is called.
+ * can be done later.
*/
virtual void setCommittedSnapshot(const Timestamp& timestamp) = 0;
/**
- * Cleans up all snapshots older than the current committed snapshot.
- *
- * Operations that have already begun using an older snapshot must continue to work using that
- * snapshot until they would normally start using a newer one. Any implementation that allows
- * that without an unbounded growth of snapshots is permitted.
- */
- virtual void cleanupUnneededSnapshots() = 0;
-
- /**
* Drops all snapshots and clears the "committed" snapshot.
*/
virtual void dropAllSnapshots() = 0;