Nubank reduced payment API latency from 1200ms to 280ms (76% reduction) through a two-phase approach. Phase 1 optimized the existing synchronous architecture by propagating context to eliminate redundant calls and collapsing non-essential service layers. Phase 2 introduced an event-driven active caching strategy that precomputes payment conditions at write-time, storing materialized views in a low-latency datastore. This architectural shift moved complexity from the read path to the write path, decoupling customer-facing latency from downstream service dependencies and infrastructure variability while maintaining correctness through mandatory fallback mechanisms.

1m read timeFrom building.nubank.com
Post cover image
Table of contents
Phase 1: Optimizing the existing architecturePhase 2: Decoupling read-time composition from back-end dependenciesResults and impact

Sort: