Expand description
Embedded storage APIs, routing helpers, batch payloads, and runtime stats.
Most applications start with EmbeddedStore, which is a shared, sharded
key-value database handle. Applications that need cheap clones of one
cross-worker handle can use SharedEmbeddedStore. Applications that pin
work to owner-local worker threads can use LocalEmbeddedStore for
exclusive &mut access to the shards assigned to that worker.
Keys and values are byte vectors (Vec<u8>). TTL arguments accepted by
write methods are milliseconds relative to the current time; expiration
methods that accept expire_at_ms use an absolute Unix timestamp in
milliseconds.
Structs§
- Borrowed
Command - Command
- Embedded
Batch Read View - Owned batch read view.
- Embedded
KeyRoute - Precomputed routing metadata for one key.
- Embedded
Read Slice - One stable byte slice captured during a batch read.
- Embedded
Read View - Owned single-value read view.
- Embedded
Session Route - Precomputed shard placement for one session prefix.
- Embedded
Shard Handle - Exclusive shard-local handle for slot-owned embedded workers.
- Embedded
Store - Shared embedded in-memory database.
- Engine
Handle - FlatMap
- Global
Stats Snapshot - Local
Embedded Batch Read View - Batch read result whose item lifetimes are tied to one worker-local store borrow.
- Local
Embedded Read Slice - Read metadata for a value returned by a
WorkerLocalEmbeddedStore. - Local
Embedded Read View - Optional single-key read result from a worker-local store.
- Local
Embedded Session Packed View - Owned packed-session view for the owned-worker embedded path.
- Local
Embedded Store - Worker-owned view of the shards assigned to one local server worker.
- Local
Embedded Store Bootstrap - Temporary container produced while partitioning an
EmbeddedStoreacross workers. - Mutation
Record - Owned
Embedded Batch Read View - Owned batch read view for the owned-worker embedded path.
- Owned
Embedded Read View - Owned single-value read view for the owned-worker embedded path.
- Owned
Embedded Session Packed View - Owned packed-session view for the owned-worker embedded path.
- Owned
Embedded Shard - Owned shard for slot-range workers.
- Owned
Embedded Worker Read Session - Long-lived worker-local read session for the absolute max embedded read path.
- Owned
Embedded Worker Shards - One worker-local shard set for the slot-owned embedded path.
- Packed
Batch - A packed copy-out batch result.
- Packed
Session Write - Packed write buffer for replacing one session’s chunk set.
- Prepared
Point Key - Precomputed routing and exact-match metadata for repeated point lookups.
- Shard
Stats Snapshot - Shared
Embedded Config - Configuration for
SharedEmbeddedStore. - Shared
Embedded Ref - Borrowed value guard returned by
SharedEmbeddedStore::get. - Shared
Embedded RefMut - Mutable point-key guard returned by
SharedEmbeddedStore::get_mut. - Shared
Embedded Store - Cloneable, lock-striped embedded cache handle.
- Shared
Embedded Vacant Entry - Vacant routed entry.
- Stored
Entry - Tier
Stats Snapshot - WalStats
Snapshot
Enums§
- Embedded
Route Mode - Selects how embedded database traffic is routed across shards.
- Local
Route Error - Indicates that a requested key or session routes to another worker’s shards.
- Local
Store Access Error - Error returned when accessing thread-local worker storage.
- Local
Store Install Error - Error returned when installing a worker-local store into thread-local state.
- Mutation
Op - Redis
Object Error - Redis
Object Result - Redis
String Lookup - Shared
Embedded Entry - Occupied or vacant routed entry.
- Shared
Embedded Lock Policy - Lock policy for
SharedEmbeddedStorestripes.
Functions§
- hash_
key - Computes the crate’s primary XXH3 key hash.
- hash_
key_ tag - Computes the primary-hash-derived key tag used by prepared point lookups.
- hash_
key_ tag_ from_ hash - Computes the key tag associated with an already-computed primary key hash.
- now_
millis - Returns the current Unix timestamp in milliseconds.
- shift_
for - stripe_
index - take_
local_ embedded_ store - with_
local_ embedded_ store
Type Aliases§
- Bytes
- Owned byte buffer used for cache keys and values.
- Embedded
Session Batch View - Session-scoped owned batch view.
- Fast
Hash Map - Hash map with the crate’s default XXH3 hasher.
- Fast
Hash Set - Hash set with the crate’s default XXH3 hasher.
- Local
Embedded Session Batch View - Session-key batch view returned by worker-local session APIs.
- Mutation
Bytes - Owned
Embedded Session Batch View