Skip to content

In development. Expect rough edges and changes. The source code is not public yet.

Jane Street Tech Blog 13 min read Case study mediumAdept

Getting from tested to battle-tested

Jane Street's Aria, a low-latency message bus with strong ordering guarantees, already had unit, simulated-network, quickcheck, AFL fuzz, version-skew, lab and chaos tests, yet adding Antithesis's deterministic-hypervisor testing surfaced two unknown bugs on the first run. A worked example traces a crash to a tip-retransmitter that, after restarting from a snapshot and before filling its ring buffer, served NUL bytes instead of an error for requests predating the snapshot. The bug had been masked for local clients by service discovery and was only exposed when cross-region clients started optimistically connecting. The investigation used Antithesis's rewind, branching and in-VM tcpdump to pin down the exact request offset versus snapshot offset.

Related posts

  • A Descent Into the Vörtex

    TigerBeetle mediumAdept

    TigerBeetle has added Vortex, a non-deterministic, generative full-system test harness that complements its Deterministic Simulation Testing by exercising real production binaries and client libraries from the outside in. A supervisor coordinates a cluster of stock replicas, a workload that checks safety properties, and language-specific client drivers (Zig and Java so far). It injects network faults through a TCP proxy, kills or pauses processes, and runs liveness checks. In four months it found two bugs: incorrect request batching in tb_client and double connection termination. Planned work includes continuous runs, upgrade testing, network partitions and storage faults.

  • The final boss of reliability: formal verification

    Turso mediumAdept

    Turso, a from-scratch SQLite rewrite, is adding formal verification via Aretta AI's Aristo, which turns natural-language intents annotated on code into formally checked properties, to complement its deterministic simulation testing and Antithesis runs. Aristo found in minutes a durability bug that DST had missed. When Turso acts as a sync replica of a cloud database, it bypasses the page cache, so pages became dirty without the dirty bit being set and were sometimes written to disk without fsync. The case for the approach is that properties like "a commit frame must be fsynced before being reported durable" are cheap to check formally. Runtime testing can miss them, because most runs happen to call fsync for unrelated reasons.

  • How we use formal modeling, lightweight simulations, and chaos testing to design reliable distributed systems

    Datadog Engineering hardMaster

    Datadog validated the design of Courier, a multi-tenant message queue built on multiple FoundationDB clusters after its March 2023 outage, by combining TLA+ formal modeling, lightweight simulations and chaos testing. Each tenant is sharded across 4 of 8 FoundationDB clusters so that no two tenants share the same set, and brokers health-check clusters and route around failures. The TLA+ spec models brokers, senders and receivers with weak fairness, and TLC checks properties such as at-least-once delivery across every reachable state. Simulations then cover what model checking cannot, such as latency, cost and scalability. Together these give design-level confidence that unit tests miss, at the cost of keeping models and simulations in sync with the design.

  • We Put a Distributed Database In the Browser – And Made a Game of It!

    TigerBeetle easyNovice

    TigerBeetle's deterministic simulator, the VOPR, is compiled to WebAssembly via Zig and wrapped in a playable browser game that runs real TigerBeetle replicas across three levels. The levels run under perfect conditions, then Jepsen-style network faults, crashes and latency, and finally up to 8% read and 9% write storage corruption per replica. The VOPR mocks all network and storage I/O in a single process, verifies linearizability and dilates time: 3.3 seconds of simulation covers 39 minutes of real-world testing, and a day covers two years. Getting the whole cluster under WebAssembly's 2 GiB memory limit was the main porting challenge, and the post contrasts VSR's round-robin view changes with Raft's randomized elections.

  • Protocol-Aware Deterministic Simulation Testing

    TigerBeetle hardMaster

    TigerBeetle's deterministic simulator (the VOPR) has full visibility into each replica's consensus and storage state, so it can check invariants that black-box tools like Jepsen or Antithesis cannot see through user-facing APIs. For safety, it asserts that every committed WAL entry has matching checksums across replicas, that LSM manifest structure is consistent everywhere, and that replicas are byte-for-byte identical, which goes deeper than the cheaper production checks that crash a diverging backup. For liveness, it enforces per-replica invariants: a replica with an uncorrupted WAL must never need cluster coordination to recover, and missing blocks must be repaired from intact copies on other replicas whenever any copy still exists.

The quest for software engineering knowledge.

Look:
Layout: