SlideShare a Scribd company logo
Split my monolith
The workshop
Photo : wikimedia
@florentpellet
LyonTechHub
@clem_bouillier @johan_alps
Split?
System resilience / Team scalability
Manage complexity
How?
We all have seen failed
modularisations.
Our hypothesis is that it's
often about the database
https://twitter.com/mathiasverraes/status/711168935798902785?lang=en
Why is a shared DB bad?
- Is it a clear interface?
- Where is the code that writes to / read from a column?
- Independent deployment?
- Can we evolve the DB schema?
Micro-services ?
Availability
99.999% uptime ?
Ex 99%^20 = 81%
Our Domain for
today
Train management
- Train routing:
- Specify itinerary between two stations
- Specify train topologies
- Schedule train
=> a train makes the same trip every day
- Booking:
- Allows our customers to book a train
- Traffic info:
- Track train on a trip
- Detect delay
- Invoicing:
- Generate invoices and credits notes
Database schema
Exercice 1:
Identify contexts in
data model
Split database
Ideal split of Trip table
Example: Table Trip
Exercise: Split the Booking table
Which domain depends on which data?
T: Traffic info
B: Booking
R: Train routing
I: Invoicing
T,B,R
B,R
T,B,R
T,B,R
T,R,I
T,R,I
T,R,I
T,I
T
T
T,R,I
T,B,I
I
I
B, I
B, R, I
B, I
T, B, R, I
T, B, R, I
B
T, B, R, I
T,B
T, B, R, I
B, I
B, I
B, I
B, R, I
T, B, I
B, I
B, I
How?
Bubble context
Autonomous bubble - synchronous
Autonomous bubble - state stream
Autonomous bubble - events
Autonomous bubble - notif. stream
Exposing legacy assets as services
Exercices
Scenario 1
Today is the day!
Everything is flooded!
Panic on board!
Lots of late trains, we need an
immediate solution.
Deadline: Yesterday
Scenario 1
Many technical problems occur
regularly in recent days
Deadline: Yesterday
We want to quickly set up a
dashboard indicating in "real time"
the number of people impacted.
We cannot afford to re-deploy the
legacy
Expected :
- Schema with modules, DB, API,
messages, models (use the legend)
- Messages frequency / data refresh
rate
- Make explicit any isolation
- Detail data for each post-its
Scenario 1 - solution
Scenario 2
The storm is over.
The dashboard made it a lot
easier to prioritize various
incidents. We'll need a solid
architecture to build upon.
Deadline: Not defined
Scenario 2
Expected :
- Schema with modules, DB, API,
messages, models (use the legend)
- Messages frequency / data refresh
rate
- Make explicit any isolation
- Detail data for each post-its
The dashboard made it a lot
easier to prioritize various
incidents. We'll need a solid
architecture to build upon.
How would you do that given
enough time?
Deadline: Not defined
Scenario 2 - a solution
Scenario 2 - data
Expected :
- Which data is duplicated
- Where does it come from
- Who is the
Writer
Reader
Many technical problems occur
regularly in recent days
Try another representation based
on data model.
Scenario 2 - data, new point of view
Scenario 2 - data - solution
Scenario 3
We have a new “nonon” offer (nogo train).
Improve business opportunity, but success
is not guaranteed.
Need to test without impact legacy and
reuse maximum functionality to reduce
costs.
Deadline: Month
Scenario 3
We have a new “nonon” offer (nogo train).
How to integrate this offer with the current
system?
- New commercial offer : other
reduction cards, options to buy (wifi,
breakfast, cancellation insurance)
- Traffic info and seat reservation
remain in the legacy
- A train is either completely “nonon”
or legacy offer
Deadline: Month
Expected (context and data) :
- Schema with modules, DB, API,
messages, models (use the legend)
- Messages frequency / data refresh
rate
- Make explicit any isolation
- Which data is duplicated
- Where does it come from
Scenario 3 - solution
Scenario 3 - solution
Final Notes
In-process sync event (method call)
Strangler fig pattern
Strangler fig pattern
paulhammant.com
Eventual Consistency is key
Most things can be
decoupled if we allow a
delay in consistency (1s,
1min, …)
Ex : The csv exports
CALM theorem
- State will ALWAYS be
consistent if we don't delete
information
Counter examples:
- Set difference
- Multiple processes doing
increment
Database change with minimal interruption
1st deploy: Add the new table/database
2nd deploy: fill the new table with values. Check
3rd deploy: New code writing to the new table
(but not reading). Possibly a migration script
4th deploy: New code or feature flip, to read
from the new table
5th deploy: remove old columns/table and old
code. (Possibly days later)
Questions
Bibliographie
Getting started with DDD when surrounded by legacy
systems
De Eric Evans
Monolith to Microservices
De Sam Newman
La passion d'apprendre
formation.hackyourjob.com
Thank you !

More Related Content

PDF
API Management - Why it matters!
PPTX
Azure data platform overview
PDF
Moving to Databricks & Delta
PPTX
SAP on Azure Technical Pitch Deck
PPTX
Sap integration salesforce_presentation
PPTX
DevOps in Salesforce AppCloud
PDF
Monoliths to microservices workshop
PPTX
Azure Migrate
API Management - Why it matters!
Azure data platform overview
Moving to Databricks & Delta
SAP on Azure Technical Pitch Deck
Sap integration salesforce_presentation
DevOps in Salesforce AppCloud
Monoliths to microservices workshop
Azure Migrate

What's hot (20)

PPTX
Introduction to Azure DevOps
PDF
Discover salesforce, dev ops and Copado CI/CD automations
PDF
Building an Enterprise-Grade Azure Governance Model
PPTX
Explore Microsoft Power Platform Center of Excellence
PPTX
Azure DevOps
PPTX
FWD Group – Insurtech Innovation Award 2023
PPTX
Continues Integration and Continuous Delivery with Azure DevOps - Deploy Anyt...
PPTX
Azure Application Modernization
PDF
Advanced Load Balancer/Traffic Manager and App Gateway for Microsoft Azure
PPTX
Azure dev ops
PPTX
How API Enablement Drives Legacy Modernization
PDF
Migrate to Microsoft Azure with Confidence
PPTX
Observability vs APM vs Monitoring Comparison
PPTX
Azure Boards.pptx
PDF
Salesforce CRM 7 domains of Success
PPTX
DevOps Transformation at Dynatrace and with Dynatrace
PDF
Journey to Cloud-Native: Where to start in your app modernization process
PPTX
Azure Cloud PPT
PPTX
Capgemini Cloud Assessment - A Pathway to Enterprise Cloud Migration
PPTX
Leveraging Azure DevOps across the Enterprise
Introduction to Azure DevOps
Discover salesforce, dev ops and Copado CI/CD automations
Building an Enterprise-Grade Azure Governance Model
Explore Microsoft Power Platform Center of Excellence
Azure DevOps
FWD Group – Insurtech Innovation Award 2023
Continues Integration and Continuous Delivery with Azure DevOps - Deploy Anyt...
Azure Application Modernization
Advanced Load Balancer/Traffic Manager and App Gateway for Microsoft Azure
Azure dev ops
How API Enablement Drives Legacy Modernization
Migrate to Microsoft Azure with Confidence
Observability vs APM vs Monitoring Comparison
Azure Boards.pptx
Salesforce CRM 7 domains of Success
DevOps Transformation at Dynatrace and with Dynatrace
Journey to Cloud-Native: Where to start in your app modernization process
Azure Cloud PPT
Capgemini Cloud Assessment - A Pathway to Enterprise Cloud Migration
Leveraging Azure DevOps across the Enterprise
Ad

Similar to Split my monolith - Devoxx (20)

PDF
Split my monolith - Workshop
PDF
Split my monolith! Workshop
PPT
Moving Towards a Streaming Architecture
PPTX
Forecasting database performance
PDF
Distributed Systems in Data Engineering
PDF
High Performance Engineering - 01-intro.pdf
PPTX
PDF
The Web Scale
PDF
Movile Internet Movel SA: A Change of Seasons: A big move to Apache Cassandra
PDF
Cassandra Summit 2015 - A Change of Seasons
PPTX
Apache Beam: A unified model for batch and stream processing data
PPT
Bhupeshbansal bigdata
PDF
Streaming Data Pipelines with Kafka (MEAP) Stefan Sprenger download pdf
PDF
"Scaling in space and time with Temporal", Andriy Lupa .pdf
PPTX
Project Deimos
PDF
Distributed Systems: scalability and high availability
PPT
Google Cloud Computing on Google Developer 2008 Day
PDF
Buy ebook Streaming Data Pipelines with Kafka (MEAP) Stefan Sprenger cheap price
PDF
An Overview of Spanner: Google's Globally Distributed Database
PDF
Download Complete Streaming Data Pipelines with Kafka (MEAP) Stefan Sprenger ...
Split my monolith - Workshop
Split my monolith! Workshop
Moving Towards a Streaming Architecture
Forecasting database performance
Distributed Systems in Data Engineering
High Performance Engineering - 01-intro.pdf
The Web Scale
Movile Internet Movel SA: A Change of Seasons: A big move to Apache Cassandra
Cassandra Summit 2015 - A Change of Seasons
Apache Beam: A unified model for batch and stream processing data
Bhupeshbansal bigdata
Streaming Data Pipelines with Kafka (MEAP) Stefan Sprenger download pdf
"Scaling in space and time with Temporal", Andriy Lupa .pdf
Project Deimos
Distributed Systems: scalability and high availability
Google Cloud Computing on Google Developer 2008 Day
Buy ebook Streaming Data Pipelines with Kafka (MEAP) Stefan Sprenger cheap price
An Overview of Spanner: Google's Globally Distributed Database
Download Complete Streaming Data Pipelines with Kafka (MEAP) Stefan Sprenger ...
Ad

More from florentpellet (15)

PDF
Comment faire un mur végétal chez soi ?
PPTX
Lyon Tech Hub
PDF
CARA - Software Craftsmanship : le chaînon manquant de l’agilité ?
PPTX
TDD outside in - Coding Dojo Lyon
PDF
Global Day of Coderetreat - Lyon 2015
PPTX
201506 mug intro
PPTX
Event storming
PPTX
CARA Coding Dojo - Outils de tests
PPTX
CARA Coding dojo - Golden Master
PPTX
CARA Coding Dojo - SOLID
PPTX
HumanTalk - Commentaires, je t'aime un peu, beaucoup, à la folie, pas du tout
PPTX
CARA Coding Dojo TDD Palindrome (décembre 2014)
PPTX
GWAB Lyon - Legacy code atelier
PPTX
Crafting workshop
PPTX
Single Page Application: Enrichissez l'expérience utilisateur
Comment faire un mur végétal chez soi ?
Lyon Tech Hub
CARA - Software Craftsmanship : le chaînon manquant de l’agilité ?
TDD outside in - Coding Dojo Lyon
Global Day of Coderetreat - Lyon 2015
201506 mug intro
Event storming
CARA Coding Dojo - Outils de tests
CARA Coding dojo - Golden Master
CARA Coding Dojo - SOLID
HumanTalk - Commentaires, je t'aime un peu, beaucoup, à la folie, pas du tout
CARA Coding Dojo TDD Palindrome (décembre 2014)
GWAB Lyon - Legacy code atelier
Crafting workshop
Single Page Application: Enrichissez l'expérience utilisateur

Recently uploaded (20)

PPTX
Oracle E-Business Suite: A Comprehensive Guide for Modern Enterprises
PPTX
Introduction to Artificial Intelligence
PDF
Audit Checklist Design Aligning with ISO, IATF, and Industry Standards — Omne...
PDF
SAP S4 Hana Brochure 3 (PTS SYSTEMS AND SOLUTIONS)
PDF
Understanding Forklifts - TECH EHS Solution
PDF
Why TechBuilder is the Future of Pickup and Delivery App Development (1).pdf
PDF
2025 Textile ERP Trends: SAP, Odoo & Oracle
PDF
Design an Analysis of Algorithms II-SECS-1021-03
PDF
Which alternative to Crystal Reports is best for small or large businesses.pdf
PPTX
Agentic AI Use Case- Contract Lifecycle Management (CLM).pptx
PPTX
Lecture 3: Operating Systems Introduction to Computer Hardware Systems
PDF
Internet Downloader Manager (IDM) Crack 6.42 Build 41
PDF
Claude Code: Everyone is a 10x Developer - A Comprehensive AI-Powered CLI Tool
PDF
Addressing The Cult of Project Management Tools-Why Disconnected Work is Hold...
PPTX
Online Work Permit System for Fast Permit Processing
PDF
Adobe Illustrator 28.6 Crack My Vision of Vector Design
PPTX
CHAPTER 2 - PM Management and IT Context
PDF
Odoo Companies in India – Driving Business Transformation.pdf
PDF
Internet Downloader Manager (IDM) Crack 6.42 Build 42 Updates Latest 2025
PDF
Flood Susceptibility Mapping Using Image-Based 2D-CNN Deep Learnin. Overview ...
Oracle E-Business Suite: A Comprehensive Guide for Modern Enterprises
Introduction to Artificial Intelligence
Audit Checklist Design Aligning with ISO, IATF, and Industry Standards — Omne...
SAP S4 Hana Brochure 3 (PTS SYSTEMS AND SOLUTIONS)
Understanding Forklifts - TECH EHS Solution
Why TechBuilder is the Future of Pickup and Delivery App Development (1).pdf
2025 Textile ERP Trends: SAP, Odoo & Oracle
Design an Analysis of Algorithms II-SECS-1021-03
Which alternative to Crystal Reports is best for small or large businesses.pdf
Agentic AI Use Case- Contract Lifecycle Management (CLM).pptx
Lecture 3: Operating Systems Introduction to Computer Hardware Systems
Internet Downloader Manager (IDM) Crack 6.42 Build 41
Claude Code: Everyone is a 10x Developer - A Comprehensive AI-Powered CLI Tool
Addressing The Cult of Project Management Tools-Why Disconnected Work is Hold...
Online Work Permit System for Fast Permit Processing
Adobe Illustrator 28.6 Crack My Vision of Vector Design
CHAPTER 2 - PM Management and IT Context
Odoo Companies in India – Driving Business Transformation.pdf
Internet Downloader Manager (IDM) Crack 6.42 Build 42 Updates Latest 2025
Flood Susceptibility Mapping Using Image-Based 2D-CNN Deep Learnin. Overview ...

Split my monolith - Devoxx

  • 1. Split my monolith The workshop Photo : wikimedia
  • 4. System resilience / Team scalability
  • 6. How? We all have seen failed modularisations. Our hypothesis is that it's often about the database https://twitter.com/mathiasverraes/status/711168935798902785?lang=en
  • 7. Why is a shared DB bad? - Is it a clear interface? - Where is the code that writes to / read from a column? - Independent deployment? - Can we evolve the DB schema?
  • 11. Train management - Train routing: - Specify itinerary between two stations - Specify train topologies - Schedule train => a train makes the same trip every day - Booking: - Allows our customers to book a train - Traffic info: - Track train on a trip - Detect delay - Invoicing: - Generate invoices and credits notes
  • 15. Ideal split of Trip table
  • 17. Exercise: Split the Booking table
  • 18. Which domain depends on which data? T: Traffic info B: Booking R: Train routing I: Invoicing T,B,R B,R T,B,R T,B,R T,R,I T,R,I T,R,I T,I T T T,R,I T,B,I I I B, I B, R, I B, I T, B, R, I T, B, R, I B T, B, R, I T,B T, B, R, I B, I B, I B, I B, R, I T, B, I B, I B, I
  • 19. How?
  • 21. Autonomous bubble - synchronous
  • 22. Autonomous bubble - state stream
  • 24. Autonomous bubble - notif. stream
  • 25. Exposing legacy assets as services
  • 27. Scenario 1 Today is the day! Everything is flooded! Panic on board! Lots of late trains, we need an immediate solution. Deadline: Yesterday
  • 28. Scenario 1 Many technical problems occur regularly in recent days Deadline: Yesterday We want to quickly set up a dashboard indicating in "real time" the number of people impacted. We cannot afford to re-deploy the legacy Expected : - Schema with modules, DB, API, messages, models (use the legend) - Messages frequency / data refresh rate - Make explicit any isolation - Detail data for each post-its
  • 29. Scenario 1 - solution
  • 30. Scenario 2 The storm is over. The dashboard made it a lot easier to prioritize various incidents. We'll need a solid architecture to build upon. Deadline: Not defined
  • 31. Scenario 2 Expected : - Schema with modules, DB, API, messages, models (use the legend) - Messages frequency / data refresh rate - Make explicit any isolation - Detail data for each post-its The dashboard made it a lot easier to prioritize various incidents. We'll need a solid architecture to build upon. How would you do that given enough time? Deadline: Not defined
  • 32. Scenario 2 - a solution
  • 33. Scenario 2 - data Expected : - Which data is duplicated - Where does it come from - Who is the Writer Reader Many technical problems occur regularly in recent days Try another representation based on data model.
  • 34. Scenario 2 - data, new point of view
  • 35. Scenario 2 - data - solution
  • 36. Scenario 3 We have a new “nonon” offer (nogo train). Improve business opportunity, but success is not guaranteed. Need to test without impact legacy and reuse maximum functionality to reduce costs. Deadline: Month
  • 37. Scenario 3 We have a new “nonon” offer (nogo train). How to integrate this offer with the current system? - New commercial offer : other reduction cards, options to buy (wifi, breakfast, cancellation insurance) - Traffic info and seat reservation remain in the legacy - A train is either completely “nonon” or legacy offer Deadline: Month Expected (context and data) : - Schema with modules, DB, API, messages, models (use the legend) - Messages frequency / data refresh rate - Make explicit any isolation - Which data is duplicated - Where does it come from
  • 38. Scenario 3 - solution
  • 39. Scenario 3 - solution
  • 41. In-process sync event (method call)
  • 44. Eventual Consistency is key Most things can be decoupled if we allow a delay in consistency (1s, 1min, …) Ex : The csv exports CALM theorem - State will ALWAYS be consistent if we don't delete information Counter examples: - Set difference - Multiple processes doing increment
  • 45. Database change with minimal interruption 1st deploy: Add the new table/database 2nd deploy: fill the new table with values. Check 3rd deploy: New code writing to the new table (but not reading). Possibly a migration script 4th deploy: New code or feature flip, to read from the new table 5th deploy: remove old columns/table and old code. (Possibly days later)
  • 47. Bibliographie Getting started with DDD when surrounded by legacy systems De Eric Evans Monolith to Microservices De Sam Newman