Two exchange feeds with different wire formats become one order-book event model, are checked for gaps, merged into a cross-venue book, and replayed in event time against a cross-venue arbitrage strategy. The engine is Java 21; this page renders the report it writes.
Venue K quotes YES bids and NO bids in whole cents; a NO bid at p appears here as a YES offer at 100 minus p. Shaded rows are prices where one venue's bid meets or crosses the other venue's offer. A venue that is resyncing contributes nothing until its snapshot lands.
Adapters. Each venue has a stateless translator from its wire shape to one normalized update: YES ladder, price as a long count of $0.0001 ticks, size in hundredths of a contract. Strings are parsed with BigDecimal and rejected if they carry sub-tick precision, so nothing is rounded silently.
Integrity. Venue K is checked by sequence number, venue P by recomputing the book hash after every change. On a break the venue's book is cleared and hidden, incrementals are buffered, and the next snapshot rebuilds it and replays only the buffered updates newer than the snapshot. Any update that would cross a venue's own book is treated as a break too.
Replay. Events run in receive-time order with a fixed venue tie-break. Orders carry an arrival time (signal plus per-venue latency) and execute against the book as it stands then, so the two legs of an arbitrage can fill differently. Same capture in, same fills out.
First messages of the sample capture, as recorded. Shapes follow the public WebSocket formats of a cents-based YES/NO exchange and a decimal-priced CLOB; tickers, ids and hashes are synthetic.