light-magic-0.5.0 has been yanked.
light-magic
A lightweight, fast and easy-to-use implementation of a persistent in-memory database.
Features
- Please note that this database is highly optimized for read operations. Writing to the database is relatively slow because each write operation involves writing data to the disk.
- Writes to the disk are done atomically meaning no data loss on a system-wide crash.
- This crate utilizes the
BTreeMapfromstd::collectionsfor storing and accessing it's tables. - Easy markup of tables using the
db!macro. - Useful data accessing functions like
searchorjoin!macro to search the data or join data together. - Can save data to a specific path after each change automatically, atomically, and persistently via
openor not viaopen_in_memory. - Supports accessing the database in parallel using a
Arc<AtomicDatabase<_>>.
...and more. Look into Todos for more planned features!
Installation
Add this to your Cargo.toml:
[]
= "0.5.0"
Examples
Using it in an axum Server? Look here: maud-magic-rs. Otherwise, look at this general example:
use ;
db!
Todos
None currently