rights reserved. Cloud Native Banking Teams empowered to execute independently, cradle to grave autonomy Rapidly evolving systems in small increments velocity low upfront cost and time to market strategy Bank needs reputation security
rights reserved. Scalability Plan • Split the workload • Each service own a different type of data from customer • Low level of interactions between customers • Safe split by customers
rights reserved. Option #1: Split Services Database • Database writes throughput are the worst bottleneck • Split service database • Change services to route queries and writes to the right shard db shard s0 db shard s1 db shard s2 backend service
rights reserved. Option #1: Known Issues • Huge effort to change all services • Solves only DB bottleneck issues • High risk of mixing business logic with infrastructure code • High risk of introducing new bugs db shard s0 db shard s1 db shard s2 backend service
rights reserved. Option #2: Scalability Units SERVICE 1 shard S0 SERVICE 3 SERVICE 2 SERVICE 1 shard S1 SERVICE 3 SERVICE 2 SERVICE 1 shard S2 SERVICE 3 SERVICE 2
rights reserved. Nubank Cloud Option #2: Scalability Units + Global Routing SERVICE 1 shard S0 SERVICE 3 SERVICE 2 SERVICE 1 shard S1 SERVICE 3 SERVICE 2 SERVICE 1 shard S2 SERVICE 3 SERVICE 2 SERVICE 1 global routing SERVICE 3 SERVICE 2 purchase
rights reserved. Nubank Stack JVM Lisp Language Functional, Immutable structures Simple and easy to learn Quick feedback cycle using REPL Gradual typing (schemas) Clojure
rights reserved. Nubank Stack Immutable, no update-in-place ACID transactions preserve informations about what and when changed Query using data structures (Datalog) Cloud-native using DynamoDB as storage Datomic for data
rights reserved. Nubank Stack Messages are Immutable and persistent Decoupling layer between micro services Async workload Fault Tolerance and Resilience (circuit-breakers and dead-letters queues) External batch jobs are transformed into internal stream processors Kafka
rights reserved. Nubank Stack Container orchestrator Ready for microservices architecture Enforces immutability on infrastructure Faster iterations Self-healing capabilities Fast and dynamic auto-scaling Kubernetes
rights reserved. Infrastructure as code definition edn map containing the definition of all deployable units deploy Internal Clojure project wrapping cloud APIs
rights reserved. Infrastructure as code - Deploy deploy Internal Clojure project wrapping cloud APIs Provisioning EC2 IAM roles Security groups Load balancers … definition edn map containing the definition of all deployable units CloudFormation Environment services deploy
rights reserved. Kubernetes Container orchestrator Ready for microservices architecture Enforces immutability on infrastructure Faster iterations Self-healing capabilities Fast and dynamic auto-scaling
rights reserved. CloudFormation Services deploy Internal Clojure project wrapping cloud APIs Provisioning EC2 IAM roles Security groups Load balancers … definition edn map containing the definition of all deployable units CloudFormation Environment services deploy
rights reserved. Lessons Learned the cloud is as elastic as our architecture scalability we are as fast as our automation velocity architecture planned for partial failures resilience infrastructure as code empowers teams autonomy