Skip to content

Commit 0dd85e5

Browse files
committed
update readme
1 parent b896819 commit 0dd85e5

File tree

1 file changed

+35
-3
lines changed

1 file changed

+35
-3
lines changed

README.md

Lines changed: 35 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
<div align="center">
22
<img src="./figures/walrus1.png"
33
alt="walrus"
4-
width="30%">
5-
<div>Walrus: A high performance storage engine in Rust</div>
4+
width="25%">
5+
<div>Walrus: A Distributed Message Streaming Engine</div>
66

77
[![Crates.io](https://img.shields.io/crates/v/walrus-rust.svg)](https://crates.io/crates/walrus-rust)
88
[![Documentation](https://docs.rs/walrus-rust/badge.svg)](https://docs.rs/walrus-rust)
@@ -11,7 +11,6 @@
1111

1212
</div>
1313

14-
## Overview
1514

1615
Walrus is a distributed message streaming platform built on a high-performance log storage engine. It provides fault-tolerant streaming with automatic leadership rotation, segment-based partitioning, and Raft consensus for metadata coordination.
1716

@@ -76,10 +75,20 @@ make cluster-bootstrap
7675
cargo run --bin walrus-cli -- --addr 127.0.0.1:9091
7776

7877
# In the CLI:
78+
79+
# create a topic named 'logs'
7980
> REGISTER logs
81+
82+
# produce a message to the topic
8083
> PUT logs "hello world"
84+
85+
# consume message from topic
8186
> GET logs
87+
88+
# get the segment states of the topic
8289
> STATE logs
90+
91+
# get cluster state
8392
> METRICS
8493
```
8594

@@ -183,6 +192,29 @@ make cluster-test-multi-topic # Multiple topics
183192
- **Consensus overhead**: Metadata only (not data path)
184193
- **Segment rollover**: ~1M entries default (~100MB depending on payload size)
185194

195+
## Correctness
196+
197+
Walrus includes a formal TLA+ specification of the distributed data plane that models segment-based sharding, lease-based write fencing, and cursor advancement across sealed segments.
198+
199+
**Specification:** [distributed-walrus/spec/DistributedWalrus.tla](distributed-walrus/spec/DistributedWalrus.tla)
200+
201+
### Verified Invariants
202+
203+
- **Domain Consistency**: Topic metadata, WAL entries, and reader cursors stay synchronized
204+
- **Single Writer per Segment**: Only the designated leader can write to each segment
205+
- **No Writes Past Open Segment**: Closed segments remain immutable after rollover
206+
- **Sealed Counts Stable**: Entry counts for sealed segments match actual WAL contents
207+
- **Read Cursor Bounds**: Cursors never exceed segment boundaries or entry counts
208+
- **Sequential Write Order**: Entries within each segment maintain strict ordering
209+
210+
### Liveness Properties
211+
212+
- **Rollover Progress**: Segments exceeding the entry threshold eventually roll over
213+
- **Read Progress**: Available entries eventually get consumed by readers
214+
215+
The specification abstracts Raft consensus as a single authoritative metadata source and models Walrus storage as per-segment entry sequences. Model checking with TLC verifies correctness under concurrent operations
216+
217+
186218
### Storage Engine Benchmarks
187219

188220
The underlying storage engine delivers exceptional performance:

0 commit comments

Comments
 (0)