RC RANDOM CHAOS

Mercury runs 2M lines of Haskell in fintech production with mostly first-time Haskellers

· via Hacker News

Original source

A couple million lines of Haskell: Production engineering at Mercury

Hacker News →

Ian Duncan, a stability engineer at fintech Mercury, describes operating roughly 2 million lines of Haskell across a 1,500-person company that processed $248B in 2025 and is pursuing a US national bank charter. Most of Mercury’s engineers had never written Haskell before joining, yet the system has held up through hypergrowth, the SVB-driven $2B deposit surge, and regulatory scrutiny. The post argues this works not because Haskell is elegant, but because it lets teams encode institutional knowledge directly into APIs and types, where it survives staff churn better than any wiki.

Duncan reframes reliability around adaptive capacity rather than pure failure prevention: a reliable system degrades gracefully, lets operators understand and adjust it, and makes the safe path the obvious one. He invokes Patrick McKenzie’s observation that in a company doubling yearly, half of coworkers always have under a year of tenure, making tribal knowledge a liability. The type system’s real production value, he argues, is operational — it forces load-bearing knowledge to be written down somewhere the compiler can enforce.

Mercury’s stability team partners with product teams pre-launch on blast radius, idempotency, rollback, and in-flight work — explicitly positioning themselves as helpers rather than quality police. The piece sets up a broader argument (continued in the post) that purity should be treated as a boundary enforced at API edges, not a property to chase everywhere.

Read the full article

Continue reading at Hacker News →

This is an AI-generated summary. Read the original for the full story.