⚠ Switch to EXCALIDRAW VIEW in the MORE OPTIONS menu of this document. ⚠ You can decompress Drawing data with the command palette: ‘Decompress current Excalidraw file’. For more info check in plugin settings under ‘Saving’
Excalidraw Data
Text Elements
Key-value store
One big hash table
key
value
session:8f3a
{user:42,…}
⏱ TTL 30 min
cart:anna
hash {1:1, 2:2}
likes:post:7
1205
top:products
sorted set
✓ GET / SET by key: O(1), in RAM ✗ “all carts that contain a Mouse?” → no query by value
Scaling: hash the key
cart:anna
hash(key) mod 16384 = slot 9123
node A slots 0–5460
node B 5461–10922
node C 10923–16383
every key belongs to exactly one node → add nodes, spread keys (sharding)