Technology

Mastering Code Migrations: How Monzo Efficiently Manages 2800 Microservices

2024-09-28

Monzo, the innovative online banking platform, operates on a colossal microservice architecture comprising over 2800 individual services. The company employs meticulous planning and advanced automation techniques to handle code migrations efficiently, enabling rapid updates while ensuring system reliability.

At the heart of Monzo's code migration strategy is a centralized team dedicated to overseeing these transitions. This approach not only minimizes delays but also ensures consistency across its diverse range of services. The significant challenge posed by such a vast microservice ecosystem is managing sweeping changes—like updating library versions to maintain functionality and security across the platform.

To combat these hurdles, Monzo established a series of foundational principles for conducting migrations. These include making processes transparent to service owners, avoiding downtime during updates, implementing gradual rollouts to reduce potential impact, and adhering to the 80/20 rule regarding automation—ensuring that the focus remains on impactful use cases rather than getting bogged down by rare anomalies.

In its quest for standardization, Monzo has chosen Go as the primary programming language for its services and has adopted a monorepo strategy for managing its source code. This allows for easier collaboration and integration across its engineering teams.

Highlighting their adaptive strategy, Will Sewell, a platform engineer at Monzo, elaborates on a case study involving the transition from OpenTracing to OpenTelemetry. The migration team kicks off the process by presenting a comprehensive proposal to the broader engineering organization via Slack or during scheduled architecture review meetings. This initial step is crucial for fostering awareness and gathering constructive feedback.

To manage these intricate changes, Monzo leverages both automated code update tools tailored to specific programming languages and manual updates for more complex scenarios. When migrating between libraries, the team prioritizes deploying a wrapper across all services. This wrapper facilitates a gradual transition, allowing for systematic switching between implementations based on user segments or a percentage of requests.

As Monzo continues to evolve and expand its microservices, mastering these sophisticated migration techniques will be integral to maintaining its reputation as a leader in innovative, reliable banking solutions. Explore how Monzo’s approach could set new standards for tech-driven industries worldwide!