summaryrefslogtreecommitdiffstats
path: root/src/test/ObjectMap/KeyValueDBMemory.h
diff options
context:
space:
mode:
authorJoao Eduardo Luis <joao.luis@inktank.com>2012-07-23 12:56:50 +0200
committerJoao Eduardo Luis <joao.luis@inktank.com>2012-07-30 19:47:41 +0200
commit9dd8a333d46f8c323e00f75391d05198cf3c8514 (patch)
treeefda8624410c023ee790196135d5ab3a7ec73720 /src/test/ObjectMap/KeyValueDBMemory.h
parentos: KeyValueDB: re-implement (prefix) iter in terms of whole-space iter (diff)
downloadceph-9dd8a333d46f8c323e00f75391d05198cf3c8514.tar.xz
ceph-9dd8a333d46f8c323e00f75391d05198cf3c8514.zip
os: KeyValueDB: implement snapshot iterators
Create a set of functions, to be implemented by derivative classes of KeyValueDB, responsible for returning an iterator with strong read-consistency guarantees. How this iterator is implemented, or by what is it backed up, is implementation specific, but it must guarantee that all reads made using this iterator are as if there were no subsequent writes to the store since we created the iterator. For instance, LevelDBStore will back this iterator with a leveldb Snapshot, while KeyValueDBMemory will perform a copy of its in-memory map. Signed-off-by: Joao Eduardo Luis <joao.luis@inktank.com>
Diffstat (limited to 'src/test/ObjectMap/KeyValueDBMemory.h')
-rw-r--r--src/test/ObjectMap/KeyValueDBMemory.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/test/ObjectMap/KeyValueDBMemory.h b/src/test/ObjectMap/KeyValueDBMemory.h
index c7bb2878238..baed9de28e0 100644
--- a/src/test/ObjectMap/KeyValueDBMemory.h
+++ b/src/test/ObjectMap/KeyValueDBMemory.h
@@ -138,4 +138,5 @@ private:
protected:
WholeSpaceIterator _get_iterator();
+ WholeSpaceIterator _get_snapshot_iterator();
};