Skip to main content

What is BULK

BULK is an L0 - a specialized execution layer that runs sophisticated risk, order book, and matching systems natively. Each BULK validator operates a dedicated binary (bulk-agave) alongside the standard Solana/Agave validator on the same machine, sharing the same identity keys. Stake weight is proportional to the validator’s Solana stake. Solana handles what it does best: decentralized asset custody, deposits, and withdrawals. BULK handles what requires purpose-built infrastructure: low-latency order matching, BULKBFT consensus on transaction ordering, and real-time risk management.

Stake Inheritance

BULK validators inherit their identity and stake weight from the Solana validator they run alongside. This means:
  • Day-one economic security. BULK’s initial validator cohort represents ~5% of Solana’s total stake, operated by 20+ independent entities.
  • Aligned incentives. Validators earn a share of exchange revenues (12.5%). Misbehavior in BULK Net results in protocol penalties (jailing), creating direct economic consequences.

Architecture

The core architecture separates pure protocol logic from I/O. Protocol crates (bulk-consensus-proto, bulk-core-proto) contain deterministic state machines - decision algorithms, type definitions, risk calculations. No network calls, no disk I/O, no Solana dependencies. I/O layers (bulk-consensus, bulk-relay, bulk-core) wrap these and handle network transport, database persistence, and Solana integration. This means the consensus and execution logic can be verified, simulated, and tested independently of any specific network implementation.

Order Lifecycle

1. Order Ingress

Traders submit signed transactions via the HTTP API or WebSocket. The ingress layer hashes each transaction for deduplication and broadcasts it to the validator set via authenticated Noise-protocol channels.

2. Consensus

Validators exchange compact transaction sketches (minisketch) and reconcile to agree on the transaction set for each round. BULKBFT consensus produces a CommittedBatch - the canonical set of transactions for that round, agreed upon by a supermajority. See BULKBFT Consensus for protocol details.

3. Deterministic Ordering

The committed batch is deterministically ordered using a multi-layered fairness scheme: Fisher-Yates shuffle seeded by the consensus-derived batch timestamp, then separation into priority queues (cancels, then post-only, then regular orders). See Fair Ordering for the full design.

4. Execution

Every validator processes the ordered batch through the identical matching engine. Pre-flight margin checks, book matching, risk callbacks, and state updates are all deterministic. Any validator that produces a different output state is immediately detectable. See Matching and Execution for the executor pipeline.

5. Settlement

Deposits and withdrawals settle on Solana.