Expand description
§BoringDB
A SQLite-based, single-process, key-value database.
You want boringdb if:
- You want high performance somewhat approaching that of databases like sled and RocksDB
- You don’t need SQL, multiprocess support, or the other cool features of SQLite
- You want SQLite’s proven reliability
§A note on durability
By default, boringdb has eventual durability: database state is guaranteed to be consistent even in the face of arbitrary crashes, and transactions are guaranteed to have “serializable” semantics. However, after a crash the database may be slightly out of date, usually by a fraction of a second.
To avoid this behavior, use the Dict::flush method to manually force synchronization with disk. Note that this comes with a fairly severe performance cost.
§Method Of Operation
BoringDB stores key/value pairs into byte vectors (Vec<u8>
).
§Examples
Examples can be found in the examples directory
Structs§
Enums§
- DbError
- A database error. Generally, these errors are quite fatal, and in application code
unwrap
ping them is usually fine.
Type Aliases§
- Boring
Result - Result type used throughout the codebase.