Wiki: Slaying the dragon - How to re-write a monolith into micro services and stay alive

For agents: Markdown version · Wiki index · Explore

Written by an LLM from machine transcripts. It can contain errors. Check the transcript before you quote it.

Summary

The speaker shares insights and a step-by-step guide on how to successfully rewrite a large legacy monolith system into modern microservices. The talk discusses the decision-making process for undertaking such a massive refactoring project, including resource allocation, handling data coexistence between old and new systems, and planning the architecture. The audience learns practical strategies for managing the migration gradually without disrupting ongoing business operations.

Key points

  • 1:14 The speaker introduces the challenge of rewriting a core legacy premium subscription monolith and outlines the discussion topics.
  • 4:19 The distinction is made between dinosaur legacy systems that should be left alone and dragon systems that are actively growing and must be rewritten.
  • 7:27 Securing resources for a long-term rewrite project requires demonstrating future velocity and new product opportunities.
  • 11:19 During a rewrite, both the old and new systems must coexist and share data safely using specific architectural patterns.
  • 14:45 New features should be written directly in the new system to prevent double work and involve the wider team in the migration.
  • 19:08 System constraints, such as security standards, should be thoroughly discussed to optimize the new microservices architecture.
  • 22:19 The migration process for each flow involves understanding the existing code, writing comprehensive tests, refactoring, and gradually shifting traffic.
  • 34:55 Celebrating milestones along the way is crucial for maintaining team morale during long-term rewrite projects.

Takeaways

  • Differentiate between stagnant legacy systems and growing systems before deciding to rewrite.
  • Migrate functionality gradually flow by flow rather than attempting a big-bang release.
  • Write new features directly into the new system to avoid maintaining code twice.
  • Celebrate small milestones to keep the team motivated during long-term migration projects.

Questions this talk answers

  • How do you decide whether a legacy system is worth rewriting or if it should be left as-is?
  • What are the best strategies for managing data synchronization between an old monolith and a new microservices architecture during a gradual migration?
  • How do you handle new feature requests while a major system rewrite is already underway?

Technologies

Hibernate, SQL, New Relic

Tags

legacy code, migration, monolith to microservices, project management, refactoring, system architecture