Expand description
§pathmap
This crate provides a key-value store with prefix compression, structural sharing, and powerful algebraic operations.
PathMap is optimized for large data sets and can be used efficiently in a multi-threaded environment.
This crate provides the low-level data structure for MORK
§Usage
Check out the book.
§kvmap
The crate name pathmap was previously used by Canmi for a different project,
kvmap (formerly published as pathmap),
which is a SQL-driven key-value store. If you are looking for Canmi’s SQL-based KVMap project, please visit:
https://github.com/canmi21/kvmap
§Getting Started
Add the following to your Cargo.toml:
pathmap = "0.2"NOTE This is pre-release software and there is going to be further API churn. We will try to respect semver, but you may want to specify an exact version to be insulated from the churn.
§Optional Cargo features
-
nightly: Uses nightly-only features including support for a customAllocator, better SIMD optimizations, etc. Requires the nightly tool-chain. -
arena_compact: Exposes an additional read-only trie format and read-zipper type that is more efficient in memory and supports mapping a large file from disk. -
jemalloc: Enables jemalloc as the default allocator. This dramatically improves scaling for write-heavy workloads and is generally recommended. The only reason it is not the default is to avoid interference with the host application’s allocator. -
zipper_tracking: Exports thezipper_trackingmodule publicly, allowing the host application to use the conflict-checking logic independently of zipper creation. -
viz: Provide APIs to inspect and visualize pathmap trie structures. Useful to observe structural sharing.
Other cargo features in this crate are intended for use by the developers of pathmap itself.
Modules§
- alloc
- Shims to allow the use of a custom
Allocatortype, if running with thenightlyfeature. Does nothing otherwise - experimental
- Extensions to the API that may or may not become permanant
- merkleization
- Functionality to optimize a trie by finding structural sharing using a temporary Merkle tree
- morphisms
- Functionality for applying various morphisms to PathMap and Zippers
- paths_
serialization - Functionality for working with the
.pathsdata format - ring
- Traits to implement ring and other algebraic operations on tries, such as union, intersection, and subtraction
- utils
- Handy conveniences and utilities to use with a PathMap
- zipper
- Cursors that can move over a trie, to inspect and modify contained elements or entire branches
Macros§
- set_
dist_ lattice - A macro to emit the DistributiveLattice implementation for a type that implements SetLattice
- set_
lattice - A macro to emit the Lattice implementation for a type that implements SetLattice
Structs§
- PathMap
- A map type that uses a trie based on byte slices (
&[u8]) known as “paths”