overdrive-db (Rust)
Zero-config embedded JSON document database with ACID transactions, AES-256 encryption, and 6 storage engines.
Install
[]
= "1.0"
Quick Start
use OverdriveDb;
use json;
API Reference
Open
// Plain open
let mut odb = open.unwrap;
// With options (password / engine)
use OpenOptions;
let mut odb = open_with_options.unwrap;
// Version
let v = version;
Tables
odb.create_table.unwrap;
odb.drop_table.unwrap;
let tables: = odb.list_tables.unwrap;
let exists: bool = odb.table_exists.unwrap;
CRUD
// Insert → returns _id String
let id = odb.insert.unwrap;
// Insert batch → returns Vec<String> of _ids
let ids = odb.insert_batch.unwrap;
// Get → Option<Value>
let doc = odb.get.unwrap;
// Update → bool (true = updated)
let updated = odb.update.unwrap;
// Delete → bool (true = deleted)
let deleted = odb.delete.unwrap;
// Count
let n = odb.count.unwrap;
Query
// SQL — returns Vec<Value>
let rows = odb.query.unwrap;
// Full-text search — returns Vec<Value>
let results = odb.search.unwrap;
Transactions
use IsolationLevel;
// Callback style (auto-commit / auto-abort)
let result = odb.transaction.unwrap;
// Manual style
let txn = odb.begin_transaction.unwrap;
match do_work
Isolation Levels:
| Variant | Value |
|---|---|
IsolationLevel::ReadUncommitted |
0 |
IsolationLevel::ReadCommitted |
1 (default) |
IsolationLevel::RepeatableRead |
2 |
IsolationLevel::Serializable |
3 |
Integrity Check
let report = odb.verify_integrity.unwrap;
println!;
6 Storage Engines
open_with_options // default
open_with_options // in-memory
open_with_options // embeddings
open_with_options // metrics/IoT
open_with_options // social graphs
open_with_options // event queue
Platform Support
| Platform | Native Library |
|---|---|
| Windows x64 | overdrive.dll |
| Linux x64 | liboverdrive.so |
| Linux ARM64 | liboverdrive.so |
| macOS x64 | liboverdrive.dylib |
| macOS ARM64 | liboverdrive.dylib |