Expand description
crossbeam-skiplist-mvcc
§Introducation
Support MVCC (Multiple Version Concurrent Control) for crossbeam-skiplist.
There are two kinds of multiple version concurrent control SkipMap:
-
nested::SkipMapThe inner is
SkipMap<K, SkipMap<u64, Option<V>>>.- Pros
- Fast latest iterators, fast read and write performance
- Cons:
- Once a key is inserted into the outer
SkipMap, the compaction can only remove the values in the innerSkipMap, this key cannot be removed any more. So, this may lead to high memory usage.
- Once a key is inserted into the outer
- Pros
-
flatten::SkipMapThe inner is
SkipMap<Key<K>, Option<V>>.- Pros
- Keys can be fully removed through compaction.
- Cons
- Unlike
nested::SkipMap,flatten::SkipMapwill store the same key multiple times, so this may lead to high memory usage. - Insertion, querying, and latest iterators may slower than
nested::SkipMap
- Unlike
- Pros
§Installation
[dependencies]
crossbeam_skiplist_mvcc = "0.3"§License
crossbeam-skiplist-mvcc is under the terms of both the MIT license and the
Apache License (Version 2.0).
See LICENSE-APACHE, LICENSE-MIT for details.
Copyright (c) 2024 Al Liu.
Modules§
- equivalentor
- Traits for key comparison in maps.
- error
- Error types for this crate.
- flatten
- A multiple version ordered map based on a lock-free skip list. See
SkipMap. - nested
- A multiple version ordered map based on a lock-free skip list. See
SkipMap. - state
- State for entries
Structs§
- Ascend
- Ascend is a comparator that compares items in ascending order.
- Descend
- Descend is a comparator that compares byte slices in ascending order.
Traits§
- Transfer
- Transfer the value from
VtoSelf::To.