Echo Persistence · 13 modules · 4 chapters
Durable state, taught as built.
EchoMQ enqueues on Valkey — fast and volatile. Echo Persistence is the floor beneath it: an in-heap accept tier, a transactional page-store built twice (Elixir on CubDB, Rust on Fjall), and replication to Tigris. The course builds that ladder from the bottom up, and every module is an interactive dive into a mechanism, not a table of machine numbers.
The course map
13 modules · 3 dives eachFoundations
Open chapter →The mechanism and the model — why durability is one knob, and the two-tier shape that turns it.The durability spectrum
The one knob behind every tier — durable records per fsync — and the two axes a queue is placed on.
Champ · the accept tier
In-heap accept with a checkpoint per K; recovery and replay as mechanism, not a number.
Persistence concepts
Volume, LSN, snapshot, the OCC commit, and the conditional-write fence — engine-neutral.
The local store
Open chapter →CubDB in depth — the append-only immutable B-tree under the native engine, and what it makes possible.CubDB architecture
Append-only immutable B-tree; how the page log is built on it; its place among the tiers.
MVCC & time travel
Zero-cost snapshots from immutability; reading a Volume at any past LSN, lock-free.
Replay & recovery
The log as truth; green boot, replica catch-up, and feed replay as one idea.
The engines
Open chapter →Built twice and bridged — the native Elixir engine, the Rust twin, replication, and the cross-runtime contract.The native Elixir engine
EchoStore.Graft.* on CubDB — the write-lock, OCC, the streamer, the lazy reader.
The Rust engine
echo_graft on Fjall + OpenDAL — the fork, the runtime, the in-memory feed.
Tigris & the fence
Push rollup, the create-if-not-exists fence, and log-head recovery — the shared remote.
The BEAM↔Rust contract
eg.4 — the byte-frozen wire, the backend, and the compositional cross-runtime proof.
Postgres WAL on the floor
PROPOSED — the consistency-first ledger’s WAL LSN onto the Graft+Tigris floor and the one cursor; the fork ruled A→B.
The platform
Open chapter →The whole picture — the bus itself, persistence beneath it, why it beats classical scheduling, and the door it opens onto BCS.EchoMQ Bus
ValKey Streams internals and the EchoMQ Stream Tier built on them — the verbs, the PEL, retention.
EchoBus + Echo Persistence
The composition — EchoMQ beside the durable floor of EP1–10; the loop across four tiers, the archive fold.
Why it beats classical scheduling
Postgres-backed Oban, honestly — what Echo separates where Oban couples, and where each one wins.
The door to BCS with Echo Persistence
The durable log plus Tables & Properties as a substrate for building systems — worked on Codemoji.
References & sources
- Echo records
- graft.engine-split.design.mdthe storage tiers and the two engines
- graft.design.mdthe two-tier design
- emq.roadmap.mdthe bus the change-feed rides
- External
- lucaong/cubdbthe native local page tier
- fjall-rs/fjallthe Rust engine’s local store
- Tigris object conditionalsthe commit fence
- Design reference
- Redis Patterns Appliedthe course sheet this design follows, re-themed