0x00 Project Roadmap
Vision: Build a production-grade cryptocurrency exchange from Hello World to Microsecond Latency. Current Status: Phase V (Extreme Optimization) - Order Commands parity complete.
π Progress Overview
This project documents the complete journey of building a 1.3M orders/sec matching engine. Below is the current status of each phase.
β Phase I: Core Matching Engine
Status: Complete
| Chapter | Title | Description |
|---|---|---|
| 0x01 | Genesis | Basic OrderBook with Vec<Order> |
| 0x02 | Float Curse | Why floats fail β u64 refactoring |
| 0x03 | Decimal World | Precision configuration system |
| 0x04 | BTree OrderBook | BTreeMap-based order book |
| 0x05 | User Balance | Account & balance management |
| 0x06 | Enforced Balance | Type-safe fund locking |
| 0x07 | Testing Framework | 1M order batch testing |
| 0x08 | Trading Pipeline | LMAX-style Ring Buffer architecture |
| 0x09 | Gateway & Persistence | HTTP API, TDengine, WebSocket, K-Line |
β Phase II: Productization
Status: Complete
| Chapter | Title | Description |
|---|---|---|
| 0x0A | Account System | PostgreSQL user management |
| 0x0A-b | ID Specification | Identity addressing rules |
| 0x0A-c | API Authentication | Ed25519 cryptographic auth |
| 0x0B | Funding & Transfer | Internal transfer architecture |
| 0x0C | Trade Fee | Maker/Taker fees + VIP discount |
πΆ Phase III: Resilience & Funding
Status: Complete
| Chapter | Title | Description | Status |
|---|---|---|---|
| 0x0D | Snapshot & Recovery | State snapshot, crash recovery | β Done |
| 0x0E | OpenAPI Integration | Swagger UI, SDK generation | β Done |
| 0x0F | Admin Dashboard | Ops Panel, KYC, hot-reload | β Done |
| 0x11 | Deposit & Withdraw | Mock Chain integration, Idempotency | β Done |
| 0x11-a | Real Chain Integration | Sentinel Service (Pull Model) | β MVP Done |
| 0x11-b | Sentinel Hardening | SegWit Fix (DEF-002) & ETH/ERC20 & ADR-005/006 | β Done |
πΆ Phase IV: Trading Integration & Verification
Status: Pending Verification
Context: The Core Engine and Trading APIs are implemented but currently tested with Mocks. This phase bridges the gap between the Real Chain (0x11) and the Matching Engine (0x01).
| Chapter | Title | Description | Status |
|---|---|---|---|
| 0x12 | Real Trading Verification | End-to-End: Bitcoind -> Sentinel -> Order -> Trade | οΏ½ Code Ready (Needs Real-Chain Test) |
| 0x13 | Market Data Experience | WebSocket Verification (Ticker, Trade, Depth) | οΏ½ Code Ready (Needs E2E Test) |
β³ Phase V: Extreme Optimization (Metal Mode)
Status: In Progress
Codename: βMetal Modeβ Goal: Push Rust to the physical limits of the hardware.
| Chapter | Title | Description |
|---|---|---|
| 0x14 | Extreme Optimization | Architecture Manifesto |
| 0x14-a | Benchmark Harness | β 100% Bit-exact Parity (FILL) |
| 0x14-b | Order Commands | β IOC, Move, Reduce (Feature Parity) |
| 0x15 | Zero-Copy | Planned |
| 0x16 | CPU Affinity | Planned |
| 0x17 | SIMD Matching | Planned |
π Key Milestones
| Git Tag | Phase | Highlights |
|---|---|---|
v0.09-f-integration-test | 0x09 | 1.3M orders/sec baseline achieved |
v0.10-a-account-system | 0x0A | PostgreSQL account integration |
v0.10-b-api-auth | 0x0A | Ed25519 authentication |
v0.0C-trade-fee | 0x0C | Maker/Taker fee system |
v0.0D-persistence | 0x0D | Universal WAL & Snapshot persistence |
v0.0F-admin-dashboard | 0x0F | Admin Operations Dashboard |
v0.11-a-funding-qa | 0x11-a | Real Chain Sentinel MVP (Deposit/Withdraw) |
v0.11-b-sentinel-hardening | 0x11-b | DEF-002 Fix, ADR-005/006, Hot Listing |
v0.14-b-order-commands | 0x14-b | β IOC, Move, Reduce (Bit-exact Parity) |
π― What Youβll Learn
- Financial Precision - Why
f64fails and how to use fixed-pointu64 - High-Performance Data Structures - BTreeMap for O(log n) order matching
- Lock-Free Concurrency - LMAX Disruptor-style Ring Buffer
- Event Sourcing - WAL-based deterministic state reconstruction
- Real-World Blockchain Integration - Handling Re-orgs, Confirmations, and UTXO management
- Production Security - Watch-only wallets & Ed25519 authentication
Last Updated: 2025-12-31