SlideShare a Scribd company logo
1 of 49
Download to read offline
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

What's hot

Gartner market guide for hybrid integration platform enabling technologies
Gartner market guide for hybrid integration platform enabling technologiesGartner market guide for hybrid integration platform enabling technologies
Gartner market guide for hybrid integration platform enabling technologies
camrituraj
 
DevOps Tutorial For Beginners | DevOps Tutorial | DevOps Tools | DevOps Train...
DevOps Tutorial For Beginners | DevOps Tutorial | DevOps Tools | DevOps Train...DevOps Tutorial For Beginners | DevOps Tutorial | DevOps Tools | DevOps Train...
DevOps Tutorial For Beginners | DevOps Tutorial | DevOps Tools | DevOps Train...
Simplilearn
 

What's hot (20)

Introduction to Event-Driven Architecture
Introduction to Event-Driven Architecture Introduction to Event-Driven Architecture
Introduction to Event-Driven Architecture
 
Observability – the good, the bad, and the ugly
Observability – the good, the bad, and the uglyObservability – the good, the bad, and the ugly
Observability – the good, the bad, and the ugly
 
Microservices Architecture - Cloud Native Apps
Microservices Architecture - Cloud Native AppsMicroservices Architecture - Cloud Native Apps
Microservices Architecture - Cloud Native Apps
 
Zuul @ Netflix SpringOne Platform
Zuul @ Netflix SpringOne PlatformZuul @ Netflix SpringOne Platform
Zuul @ Netflix SpringOne Platform
 
Api design best practice
Api design best practiceApi design best practice
Api design best practice
 
Apache Kafka as Event Streaming Platform for Microservice Architectures
Apache Kafka as Event Streaming Platform for Microservice ArchitecturesApache Kafka as Event Streaming Platform for Microservice Architectures
Apache Kafka as Event Streaming Platform for Microservice Architectures
 
Gartner market guide for hybrid integration platform enabling technologies
Gartner market guide for hybrid integration platform enabling technologiesGartner market guide for hybrid integration platform enabling technologies
Gartner market guide for hybrid integration platform enabling technologies
 
Azure Migration Program Overview
Azure Migration Program OverviewAzure Migration Program Overview
Azure Migration Program Overview
 
Interface Fact Sheets in LeanIX Enterprise Architecture Management
Interface Fact Sheets in LeanIX Enterprise Architecture ManagementInterface Fact Sheets in LeanIX Enterprise Architecture Management
Interface Fact Sheets in LeanIX Enterprise Architecture Management
 
Taylor Wicksell and Tom Gianos at SpringOne Platform 2019
Taylor Wicksell and Tom Gianos at SpringOne Platform 2019Taylor Wicksell and Tom Gianos at SpringOne Platform 2019
Taylor Wicksell and Tom Gianos at SpringOne Platform 2019
 
SAFe portfolio management @ Knowit nov 28
SAFe portfolio management @ Knowit nov 28SAFe portfolio management @ Knowit nov 28
SAFe portfolio management @ Knowit nov 28
 
Hexagonal And Beyond
Hexagonal And BeyondHexagonal And Beyond
Hexagonal And Beyond
 
Cloud architecture with the ArchiMate Language
Cloud architecture with the ArchiMate LanguageCloud architecture with the ArchiMate Language
Cloud architecture with the ArchiMate Language
 
IT4IT - The Full Story for Digital Transformation - Part 2
IT4IT - The Full Story for Digital Transformation - Part 2IT4IT - The Full Story for Digital Transformation - Part 2
IT4IT - The Full Story for Digital Transformation - Part 2
 
Digital Transformation is Cloud-Powered
Digital Transformation is Cloud-PoweredDigital Transformation is Cloud-Powered
Digital Transformation is Cloud-Powered
 
Cloud Architecture - Multi Cloud, Edge, On-Premise
Cloud Architecture - Multi Cloud, Edge, On-PremiseCloud Architecture - Multi Cloud, Edge, On-Premise
Cloud Architecture - Multi Cloud, Edge, On-Premise
 
Observability
ObservabilityObservability
Observability
 
Event Sourcing & CQRS, Kafka, Rabbit MQ
Event Sourcing & CQRS, Kafka, Rabbit MQEvent Sourcing & CQRS, Kafka, Rabbit MQ
Event Sourcing & CQRS, Kafka, Rabbit MQ
 
Leveraging Generative AI to Accelerate Graph Innovation for National Security...
Leveraging Generative AI to Accelerate Graph Innovation for National Security...Leveraging Generative AI to Accelerate Graph Innovation for National Security...
Leveraging Generative AI to Accelerate Graph Innovation for National Security...
 
DevOps Tutorial For Beginners | DevOps Tutorial | DevOps Tools | DevOps Train...
DevOps Tutorial For Beginners | DevOps Tutorial | DevOps Tools | DevOps Train...DevOps Tutorial For Beginners | DevOps Tutorial | DevOps Tools | DevOps Train...
DevOps Tutorial For Beginners | DevOps Tutorial | DevOps Tools | DevOps Train...
 

Similar to Split my monolith - Devoxx

Moving Towards a Streaming Architecture
Moving Towards a Streaming ArchitectureMoving Towards a Streaming Architecture
Moving Towards a Streaming Architecture
Gabriele Modena
 
Bhupeshbansal bigdata
Bhupeshbansal bigdata Bhupeshbansal bigdata
Bhupeshbansal bigdata
Bhupesh Bansal
 
Project Deimos
Project DeimosProject Deimos
Project Deimos
Simon Suo
 
Distributed Systems: scalability and high availability
Distributed Systems: scalability and high availabilityDistributed Systems: scalability and high availability
Distributed Systems: scalability and high availability
Renato Lucindo
 
Google Cloud Computing on Google Developer 2008 Day
Google Cloud Computing on Google Developer 2008 DayGoogle Cloud Computing on Google Developer 2008 Day
Google Cloud Computing on Google Developer 2008 Day
programmermag
 
Achieving Real-time Ingestion and Analysis of Security Events through Kafka a...
Achieving Real-time Ingestion and Analysis of Security Events through Kafka a...Achieving Real-time Ingestion and Analysis of Security Events through Kafka a...
Achieving Real-time Ingestion and Analysis of Security Events through Kafka a...
Kevin Mao
 

Similar to Split my monolith - Devoxx (20)

Split my monolith - Workshop
Split my monolith - WorkshopSplit my monolith - Workshop
Split my monolith - Workshop
 
Split my monolith! Workshop
Split my monolith! Workshop Split my monolith! Workshop
Split my monolith! Workshop
 
Moving Towards a Streaming Architecture
Moving Towards a Streaming ArchitectureMoving Towards a Streaming Architecture
Moving Towards a Streaming Architecture
 
Forecasting database performance
Forecasting database performanceForecasting database performance
Forecasting database performance
 
Distributed Systems in Data Engineering
Distributed Systems in Data EngineeringDistributed Systems in Data Engineering
Distributed Systems in Data Engineering
 
NoSQL
NoSQLNoSQL
NoSQL
 
The Web Scale
The Web ScaleThe Web Scale
The Web Scale
 
Movile Internet Movel SA: A Change of Seasons: A big move to Apache Cassandra
Movile Internet Movel SA: A Change of Seasons: A big move to Apache CassandraMovile Internet Movel SA: A Change of Seasons: A big move to Apache Cassandra
Movile Internet Movel SA: A Change of Seasons: A big move to Apache Cassandra
 
Cassandra Summit 2015 - A Change of Seasons
Cassandra Summit 2015 - A Change of SeasonsCassandra Summit 2015 - A Change of Seasons
Cassandra Summit 2015 - A Change of Seasons
 
Apache Beam: A unified model for batch and stream processing data
Apache Beam: A unified model for batch and stream processing dataApache Beam: A unified model for batch and stream processing data
Apache Beam: A unified model for batch and stream processing data
 
Bhupeshbansal bigdata
Bhupeshbansal bigdata Bhupeshbansal bigdata
Bhupeshbansal bigdata
 
Project Deimos
Project DeimosProject Deimos
Project Deimos
 
Distributed Systems: scalability and high availability
Distributed Systems: scalability and high availabilityDistributed Systems: scalability and high availability
Distributed Systems: scalability and high availability
 
Google Cloud Computing on Google Developer 2008 Day
Google Cloud Computing on Google Developer 2008 DayGoogle Cloud Computing on Google Developer 2008 Day
Google Cloud Computing on Google Developer 2008 Day
 
An Overview of Spanner: Google's Globally Distributed Database
An Overview of Spanner: Google's Globally Distributed DatabaseAn Overview of Spanner: Google's Globally Distributed Database
An Overview of Spanner: Google's Globally Distributed Database
 
Resilience: the key requirement of a [big] [data] architecture - StampedeCon...
Resilience: the key requirement of a [big] [data] architecture  - StampedeCon...Resilience: the key requirement of a [big] [data] architecture  - StampedeCon...
Resilience: the key requirement of a [big] [data] architecture - StampedeCon...
 
Waters Grid & HPC Course
Waters Grid & HPC CourseWaters Grid & HPC Course
Waters Grid & HPC Course
 
Cloud Computing Berkeley.pdf
Cloud Computing Berkeley.pdfCloud Computing Berkeley.pdf
Cloud Computing Berkeley.pdf
 
Dori Exterman, Considerations for choosing the parallel computing strategy th...
Dori Exterman, Considerations for choosing the parallel computing strategy th...Dori Exterman, Considerations for choosing the parallel computing strategy th...
Dori Exterman, Considerations for choosing the parallel computing strategy th...
 
Achieving Real-time Ingestion and Analysis of Security Events through Kafka a...
Achieving Real-time Ingestion and Analysis of Security Events through Kafka a...Achieving Real-time Ingestion and Analysis of Security Events through Kafka a...
Achieving Real-time Ingestion and Analysis of Security Events through Kafka a...
 

More from florentpellet

More from florentpellet (15)

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

Recently uploaded

Mastering Windows 7 A Comprehensive Guide for Power Users .pdf
Mastering Windows 7 A Comprehensive Guide for Power Users .pdfMastering Windows 7 A Comprehensive Guide for Power Users .pdf
Mastering Windows 7 A Comprehensive Guide for Power Users .pdf
mbmh111980
 
AI/ML Infra Meetup | Improve Speed and GPU Utilization for Model Training & S...
AI/ML Infra Meetup | Improve Speed and GPU Utilization for Model Training & S...AI/ML Infra Meetup | Improve Speed and GPU Utilization for Model Training & S...
AI/ML Infra Meetup | Improve Speed and GPU Utilization for Model Training & S...
Alluxio, Inc.
 

Recently uploaded (20)

AI Hackathon.pptx
AI                        Hackathon.pptxAI                        Hackathon.pptx
AI Hackathon.pptx
 
Secure Software Ecosystem Teqnation 2024
Secure Software Ecosystem Teqnation 2024Secure Software Ecosystem Teqnation 2024
Secure Software Ecosystem Teqnation 2024
 
APVP,apvp apvp High quality supplier safe spot transport, 98% purity
APVP,apvp apvp High quality supplier safe spot transport, 98% purityAPVP,apvp apvp High quality supplier safe spot transport, 98% purity
APVP,apvp apvp High quality supplier safe spot transport, 98% purity
 
A Python-based approach to data loading in TM1 - Using Airflow as an ETL for TM1
A Python-based approach to data loading in TM1 - Using Airflow as an ETL for TM1A Python-based approach to data loading in TM1 - Using Airflow as an ETL for TM1
A Python-based approach to data loading in TM1 - Using Airflow as an ETL for TM1
 
Mastering Windows 7 A Comprehensive Guide for Power Users .pdf
Mastering Windows 7 A Comprehensive Guide for Power Users .pdfMastering Windows 7 A Comprehensive Guide for Power Users .pdf
Mastering Windows 7 A Comprehensive Guide for Power Users .pdf
 
GraphSummit Stockholm - Neo4j - Knowledge Graphs and Product Updates
GraphSummit Stockholm - Neo4j - Knowledge Graphs and Product UpdatesGraphSummit Stockholm - Neo4j - Knowledge Graphs and Product Updates
GraphSummit Stockholm - Neo4j - Knowledge Graphs and Product Updates
 
AI/ML Infra Meetup | Perspective on Deep Learning Framework
AI/ML Infra Meetup | Perspective on Deep Learning FrameworkAI/ML Infra Meetup | Perspective on Deep Learning Framework
AI/ML Infra Meetup | Perspective on Deep Learning Framework
 
AI/ML Infra Meetup | Reducing Prefill for LLM Serving in RAG
AI/ML Infra Meetup | Reducing Prefill for LLM Serving in RAGAI/ML Infra Meetup | Reducing Prefill for LLM Serving in RAG
AI/ML Infra Meetup | Reducing Prefill for LLM Serving in RAG
 
how-to-download-files-safely-from-the-internet.pdf
how-to-download-files-safely-from-the-internet.pdfhow-to-download-files-safely-from-the-internet.pdf
how-to-download-files-safely-from-the-internet.pdf
 
Top Mobile App Development Companies 2024
Top Mobile App Development Companies 2024Top Mobile App Development Companies 2024
Top Mobile App Development Companies 2024
 
Entropy, Software Quality, and Innovation (presented at Princeton Plasma Phys...
Entropy, Software Quality, and Innovation (presented at Princeton Plasma Phys...Entropy, Software Quality, and Innovation (presented at Princeton Plasma Phys...
Entropy, Software Quality, and Innovation (presented at Princeton Plasma Phys...
 
AI/ML Infra Meetup | Improve Speed and GPU Utilization for Model Training & S...
AI/ML Infra Meetup | Improve Speed and GPU Utilization for Model Training & S...AI/ML Infra Meetup | Improve Speed and GPU Utilization for Model Training & S...
AI/ML Infra Meetup | Improve Speed and GPU Utilization for Model Training & S...
 
A Guideline to Zendesk to Re:amaze Data Migration
A Guideline to Zendesk to Re:amaze Data MigrationA Guideline to Zendesk to Re:amaze Data Migration
A Guideline to Zendesk to Re:amaze Data Migration
 
Crafting the Perfect Measurement Sheet with PLM Integration
Crafting the Perfect Measurement Sheet with PLM IntegrationCrafting the Perfect Measurement Sheet with PLM Integration
Crafting the Perfect Measurement Sheet with PLM Integration
 
10 Essential Software Testing Tools You Need to Know About.pdf
10 Essential Software Testing Tools You Need to Know About.pdf10 Essential Software Testing Tools You Need to Know About.pdf
10 Essential Software Testing Tools You Need to Know About.pdf
 
What need to be mastered as AI-Powered Java Developers
What need to be mastered as AI-Powered Java DevelopersWhat need to be mastered as AI-Powered Java Developers
What need to be mastered as AI-Powered Java Developers
 
KLARNA - Language Models and Knowledge Graphs: A Systems Approach
KLARNA -  Language Models and Knowledge Graphs: A Systems ApproachKLARNA -  Language Models and Knowledge Graphs: A Systems Approach
KLARNA - Language Models and Knowledge Graphs: A Systems Approach
 
5 Reasons Driving Warehouse Management Systems Demand
5 Reasons Driving Warehouse Management Systems Demand5 Reasons Driving Warehouse Management Systems Demand
5 Reasons Driving Warehouse Management Systems Demand
 
Facemoji Keyboard released its 2023 State of Emoji report, outlining the most...
Facemoji Keyboard released its 2023 State of Emoji report, outlining the most...Facemoji Keyboard released its 2023 State of Emoji report, outlining the most...
Facemoji Keyboard released its 2023 State of Emoji report, outlining the most...
 
SQL Injection Introduction and Prevention
SQL Injection Introduction and PreventionSQL Injection Introduction and Prevention
SQL Injection Introduction and Prevention
 

Split my monolith - Devoxx