SlideShare a Scribd company logo
1 of 17
Prepared by @saflimbenly -2016Prepared by @saflimbenly -2016
Monolith to
Microservices
How to implement Application Modernization in 2016
Prepared by @saflimbenly -2016
Monolith
● Simple to test
● Simple to deploy
● Scale by multiple copies
● ACID (Atomicity,
Consistency, Isolation,
Durability)
● Complex
● Slow down development
● Scale problem
● Reliability (memory leak, db
lock)
● Hiring
Prepared by @saflimbenly -2016
Microservices
Split the application into smaller and
interconnected services.
● Develop, Deploy, Scale Independently
● Domain-driven Design (Core / Process Service)
● Event-driven Data Management
● DB schema per service (loose coupling)
● Inter-process Communication (RPC, message
Driven API)
● Determine the service size (How big is 1 service?)
● Distributed system (what IPC has to be used?)
● Partitioned DB architecture (ERD of the application)
● Testing, Deploy, Manage
● Change multiple Service (complex business
process)
Prepared by @saflimbenly -2016
Example
of Microservices
Prepared by @saflimbenly -2016
Microservices Principle
● Each Microservices Has Its Own Build
● Business Logic is Stateless
● Data Layer is Cached
● Separate Data Source
● Independently Deployable
● Fully Contained
Prepared by @saflimbenly -2016
Microservices Best Practice
● Design for Automation
(Continuous Delivery)
● Design for Failure
○ Service load balancing
○ Automation scaling
○ Retry on failure
○ Circuit breaker
○ Bulkhead
○ Timeouts
● Design for Data Separation
● Design for Integrity
○ Transaction
○ Read-Write
○ Event-driven Design
○ Transaction IDs
● Design for Performance
○ Load test
○ Technology
○ API Gateway & LB
○ Cache
Prepared by @saflimbenly -2016
Migration Approaches
Strangler PatternBig Bang
Prepared by @saflimbenly -2016
Strategy 1 - Stop Digging
● The Law of Holes
● Anti-corruption Layer
● Domain-Driven Design
Prepared by @saflimbenly -2016
Strategy 2 - Split Frontend and Backend
● Presentation Layer
● Business Logic Layer
● Data-Access Layer
● Using latest technology without
hurting current stack
● Only provide API call from
Backend
Prepared by @saflimbenly -2016
Strategy 3 - Extract Services
● Prioritize which
module to convert
● Paying “technical
debt” one service at
the time.
Step 1
Prepared by @saflimbenly -2016
Strategy 3 - Extract Services (Cont.)
Step 2
Prepared by @saflimbenly -2016
Architecture Overview
● One Service One Data Source
● Implement DDD
● Using CQRS / Event Sourcing
pattern
● Each service component can be
one containers
● API Gateway handle : request
routing, composition, service
discovery.
Prepared by @saflimbenly -2016
How We Are Going To Do It
● Agile Scrum/Kanban
● Team can be change on each sprint/project.
● Every member can have a chance to involve in this
process, depends on knowledge they have in particular
module.
Prepared by @saflimbenly -2016
API Gateway (In Progress)
- Request routing
- Composition
- Protocol Transaction
- Not “One-Size-Fit-All” but “One-Call-Serve-
All”
- Service Invocation
- Service Discovery
- Mismatch
- Different protocols
- Refactor
Prepared by @saflimbenly -2016
Event-driven Data Management (In Progress)
- NoSQL
- ElasticSearch
- Neo4j
- Geo-location
Preserve Atomicity
- Publishing Event using Local Transaction
- Mining a Database Transaction Log
- Event Sourcing
- Implement business transaction that
maintain consistency across multiple
services
- Implement query to retrieve data from
multiple services
Prepared by @saflimbenly -2016
Cross-cutting Concerns (In Progress)
● Security
● Logging
● Health Checks
● Integration Testing
Prepared by @saflimbenly -2016
Technology Stack
Java EE and DDD :
● JAX-RS
● Stateless EJB
● JPA (Entities, Embeddable, EM)
● Websocket
● Concurrency Utilities
● Apache Kafka
● etc...
DevOps, Crosscutting, Microservices :
● Git
● Docker / Dokku
● Jenkins
● Redis
● PostgreSQL
● NoSQL
● Swagger
● Logback
● etc...

More Related Content

What's hot

Monoliths to Microservices: App Transformation - introduction
Monoliths to Microservices: App Transformation - introductionMonoliths to Microservices: App Transformation - introduction
Monoliths to Microservices: App Transformation - introductionTiera Fann, MBA
 
Monitoring Containerized Application in Alibaba Cloud
Monitoring Containerized Application in Alibaba CloudMonitoring Containerized Application in Alibaba Cloud
Monitoring Containerized Application in Alibaba Cloudgavaskar s
 
WSO2 API microgateway introduction
WSO2 API microgateway introductionWSO2 API microgateway introduction
WSO2 API microgateway introductionChanaka Fernando
 
API Gateway: Nginx way
API Gateway: Nginx wayAPI Gateway: Nginx way
API Gateway: Nginx wayinovia
 
[WSO2Con EU 2018] Enabling Agile Integration Teams
[WSO2Con EU 2018] Enabling Agile Integration Teams[WSO2Con EU 2018] Enabling Agile Integration Teams
[WSO2Con EU 2018] Enabling Agile Integration TeamsWSO2
 
Schemas Beyond The Edge
Schemas Beyond The EdgeSchemas Beyond The Edge
Schemas Beyond The Edgeconfluent
 
Lieven Vandegaer from MEDIAGENIX - Orchestrating a video-on-demand pipeline w...
Lieven Vandegaer from MEDIAGENIX - Orchestrating a video-on-demand pipeline w...Lieven Vandegaer from MEDIAGENIX - Orchestrating a video-on-demand pipeline w...
Lieven Vandegaer from MEDIAGENIX - Orchestrating a video-on-demand pipeline w...camunda services GmbH
 
How do async ap is survive in a rest world
How do async ap is survive in a rest world How do async ap is survive in a rest world
How do async ap is survive in a rest world Luca Mattia Ferrari
 
5 Pillars of Building Enterprise0grade APIs
5 Pillars of Building Enterprise0grade APIs5 Pillars of Building Enterprise0grade APIs
5 Pillars of Building Enterprise0grade APIsWSO2
 
Wso2 api microgateway deployment patterns
Wso2 api microgateway deployment patternsWso2 api microgateway deployment patterns
Wso2 api microgateway deployment patternsChanaka Fernando
 
[WSO2Con USA 2018] Up-leveling Brownfield Integration
[WSO2Con USA 2018] Up-leveling Brownfield Integration [WSO2Con USA 2018] Up-leveling Brownfield Integration
[WSO2Con USA 2018] Up-leveling Brownfield Integration WSO2
 
Explore the Latest on WSO2 Identity Server 5.11
Explore the Latest on WSO2 Identity Server 5.11Explore the Latest on WSO2 Identity Server 5.11
Explore the Latest on WSO2 Identity Server 5.11WSO2
 
A Go-Through With Lagom Application
A Go-Through With Lagom ApplicationA Go-Through With Lagom Application
A Go-Through With Lagom ApplicationKnoldus Inc.
 
MongoDB and Machine Learning with Flowable
MongoDB and Machine Learning with FlowableMongoDB and Machine Learning with Flowable
MongoDB and Machine Learning with FlowableFlowable
 
[WSO2Con EU 2018] Up-Leveling Brownfield Integration
[WSO2Con EU 2018] Up-Leveling Brownfield Integration[WSO2Con EU 2018] Up-Leveling Brownfield Integration
[WSO2Con EU 2018] Up-Leveling Brownfield IntegrationWSO2
 
Icinga Camp Bangalore - Enterprise exceptions
Icinga Camp Bangalore - Enterprise exceptions Icinga Camp Bangalore - Enterprise exceptions
Icinga Camp Bangalore - Enterprise exceptions Icinga
 
What’s New with Flowable?
What’s New with Flowable?What’s New with Flowable?
What’s New with Flowable?Flowable
 
Expanding OEM Opportunities with WSO2
Expanding OEM Opportunities with WSO2Expanding OEM Opportunities with WSO2
Expanding OEM Opportunities with WSO2WSO2
 
Api gateway : To be or not to be
Api gateway : To be or not to beApi gateway : To be or not to be
Api gateway : To be or not to beJaewoo Ahn
 
[WSO2 Summit Americas 2020] Creating Smart Endpoints Using Integration Micros...
[WSO2 Summit Americas 2020] Creating Smart Endpoints Using Integration Micros...[WSO2 Summit Americas 2020] Creating Smart Endpoints Using Integration Micros...
[WSO2 Summit Americas 2020] Creating Smart Endpoints Using Integration Micros...WSO2
 

What's hot (20)

Monoliths to Microservices: App Transformation - introduction
Monoliths to Microservices: App Transformation - introductionMonoliths to Microservices: App Transformation - introduction
Monoliths to Microservices: App Transformation - introduction
 
Monitoring Containerized Application in Alibaba Cloud
Monitoring Containerized Application in Alibaba CloudMonitoring Containerized Application in Alibaba Cloud
Monitoring Containerized Application in Alibaba Cloud
 
WSO2 API microgateway introduction
WSO2 API microgateway introductionWSO2 API microgateway introduction
WSO2 API microgateway introduction
 
API Gateway: Nginx way
API Gateway: Nginx wayAPI Gateway: Nginx way
API Gateway: Nginx way
 
[WSO2Con EU 2018] Enabling Agile Integration Teams
[WSO2Con EU 2018] Enabling Agile Integration Teams[WSO2Con EU 2018] Enabling Agile Integration Teams
[WSO2Con EU 2018] Enabling Agile Integration Teams
 
Schemas Beyond The Edge
Schemas Beyond The EdgeSchemas Beyond The Edge
Schemas Beyond The Edge
 
Lieven Vandegaer from MEDIAGENIX - Orchestrating a video-on-demand pipeline w...
Lieven Vandegaer from MEDIAGENIX - Orchestrating a video-on-demand pipeline w...Lieven Vandegaer from MEDIAGENIX - Orchestrating a video-on-demand pipeline w...
Lieven Vandegaer from MEDIAGENIX - Orchestrating a video-on-demand pipeline w...
 
How do async ap is survive in a rest world
How do async ap is survive in a rest world How do async ap is survive in a rest world
How do async ap is survive in a rest world
 
5 Pillars of Building Enterprise0grade APIs
5 Pillars of Building Enterprise0grade APIs5 Pillars of Building Enterprise0grade APIs
5 Pillars of Building Enterprise0grade APIs
 
Wso2 api microgateway deployment patterns
Wso2 api microgateway deployment patternsWso2 api microgateway deployment patterns
Wso2 api microgateway deployment patterns
 
[WSO2Con USA 2018] Up-leveling Brownfield Integration
[WSO2Con USA 2018] Up-leveling Brownfield Integration [WSO2Con USA 2018] Up-leveling Brownfield Integration
[WSO2Con USA 2018] Up-leveling Brownfield Integration
 
Explore the Latest on WSO2 Identity Server 5.11
Explore the Latest on WSO2 Identity Server 5.11Explore the Latest on WSO2 Identity Server 5.11
Explore the Latest on WSO2 Identity Server 5.11
 
A Go-Through With Lagom Application
A Go-Through With Lagom ApplicationA Go-Through With Lagom Application
A Go-Through With Lagom Application
 
MongoDB and Machine Learning with Flowable
MongoDB and Machine Learning with FlowableMongoDB and Machine Learning with Flowable
MongoDB and Machine Learning with Flowable
 
[WSO2Con EU 2018] Up-Leveling Brownfield Integration
[WSO2Con EU 2018] Up-Leveling Brownfield Integration[WSO2Con EU 2018] Up-Leveling Brownfield Integration
[WSO2Con EU 2018] Up-Leveling Brownfield Integration
 
Icinga Camp Bangalore - Enterprise exceptions
Icinga Camp Bangalore - Enterprise exceptions Icinga Camp Bangalore - Enterprise exceptions
Icinga Camp Bangalore - Enterprise exceptions
 
What’s New with Flowable?
What’s New with Flowable?What’s New with Flowable?
What’s New with Flowable?
 
Expanding OEM Opportunities with WSO2
Expanding OEM Opportunities with WSO2Expanding OEM Opportunities with WSO2
Expanding OEM Opportunities with WSO2
 
Api gateway : To be or not to be
Api gateway : To be or not to beApi gateway : To be or not to be
Api gateway : To be or not to be
 
[WSO2 Summit Americas 2020] Creating Smart Endpoints Using Integration Micros...
[WSO2 Summit Americas 2020] Creating Smart Endpoints Using Integration Micros...[WSO2 Summit Americas 2020] Creating Smart Endpoints Using Integration Micros...
[WSO2 Summit Americas 2020] Creating Smart Endpoints Using Integration Micros...
 

Similar to How to move from Monolith to Microservice

'How to build efficient backend based on microservice architecture' by Anton ...
'How to build efficient backend based on microservice architecture' by Anton ...'How to build efficient backend based on microservice architecture' by Anton ...
'How to build efficient backend based on microservice architecture' by Anton ...OdessaJS Conf
 
Microservice Workshop Hands On
Microservice Workshop Hands On Microservice Workshop Hands On
Microservice Workshop Hands On Ram G Suri
 
Full lifecycle of a microservice
Full lifecycle of a microserviceFull lifecycle of a microservice
Full lifecycle of a microserviceLuigi Bennardis
 
Yuriy Chapran - Building microservices.
Yuriy Chapran - Building microservices.Yuriy Chapran - Building microservices.
Yuriy Chapran - Building microservices.Yuriy Chapran
 
Ledingkart Meetup #1: Monolithic to microservices in action
Ledingkart Meetup #1: Monolithic to microservices in actionLedingkart Meetup #1: Monolithic to microservices in action
Ledingkart Meetup #1: Monolithic to microservices in actionMukesh Singh
 
PyCONKE meetup 2019: Microservices
PyCONKE meetup 2019: MicroservicesPyCONKE meetup 2019: Microservices
PyCONKE meetup 2019: MicroservicesSamuel Olembo
 
apidays LIVE Paris - GraphQL meshes by Jens Neuse
apidays LIVE Paris - GraphQL meshes by Jens Neuseapidays LIVE Paris - GraphQL meshes by Jens Neuse
apidays LIVE Paris - GraphQL meshes by Jens Neuseapidays
 
Microservices architecture ext
Microservices architecture extMicroservices architecture ext
Microservices architecture extVikash Kodati
 
Rez gateway - RezOS - innovate the future
Rez gateway - RezOS -   innovate the futureRez gateway - RezOS -   innovate the future
Rez gateway - RezOS - innovate the futureindikaMaligaspe
 
Rez gateway (RezOS) innovate the future
Rez gateway  (RezOS) innovate the futureRez gateway  (RezOS) innovate the future
Rez gateway (RezOS) innovate the futureindikaMaligaspe
 
Twelve-Factor application pattern with Spring Framework
Twelve-Factor application pattern with Spring FrameworkTwelve-Factor application pattern with Spring Framework
Twelve-Factor application pattern with Spring Frameworkdinkar thakur
 
Challenges In Modern Application
Challenges In Modern ApplicationChallenges In Modern Application
Challenges In Modern ApplicationRahul Kumar Gupta
 
Changing Views on Integration (AUSOUG Webinar Series, May 2020)
Changing Views on Integration (AUSOUG Webinar Series, May 2020)Changing Views on Integration (AUSOUG Webinar Series, May 2020)
Changing Views on Integration (AUSOUG Webinar Series, May 2020)Lucas Jellema
 
MuleSoft Manchester Meetup #4 slides 11th February 2021
MuleSoft Manchester Meetup #4 slides 11th February 2021MuleSoft Manchester Meetup #4 slides 11th February 2021
MuleSoft Manchester Meetup #4 slides 11th February 2021Ieva Navickaite
 
MuleSoft Meetup Adelaide 7th April 2021
MuleSoft Meetup Adelaide 7th April 2021MuleSoft Meetup Adelaide 7th April 2021
MuleSoft Meetup Adelaide 7th April 2021Nicholas Bowman
 
Moving existing apps to the cloud
 Moving existing apps to the cloud Moving existing apps to the cloud
Moving existing apps to the cloudTiera Fann, MBA
 
Introduction to microservices
Introduction to microservicesIntroduction to microservices
Introduction to microservicesAnil Allewar
 
Lagom : Reactive microservice framework
Lagom : Reactive microservice frameworkLagom : Reactive microservice framework
Lagom : Reactive microservice frameworkFabrice Sznajderman
 
MuleSoft London Community October 2017 - Hybrid and SAP Integration
MuleSoft London Community October 2017 - Hybrid and SAP IntegrationMuleSoft London Community October 2017 - Hybrid and SAP Integration
MuleSoft London Community October 2017 - Hybrid and SAP IntegrationPace Integration
 

Similar to How to move from Monolith to Microservice (20)

'How to build efficient backend based on microservice architecture' by Anton ...
'How to build efficient backend based on microservice architecture' by Anton ...'How to build efficient backend based on microservice architecture' by Anton ...
'How to build efficient backend based on microservice architecture' by Anton ...
 
Microservice Workshop Hands On
Microservice Workshop Hands On Microservice Workshop Hands On
Microservice Workshop Hands On
 
Full lifecycle of a microservice
Full lifecycle of a microserviceFull lifecycle of a microservice
Full lifecycle of a microservice
 
Yuriy Chapran - Building microservices.
Yuriy Chapran - Building microservices.Yuriy Chapran - Building microservices.
Yuriy Chapran - Building microservices.
 
Ledingkart Meetup #1: Monolithic to microservices in action
Ledingkart Meetup #1: Monolithic to microservices in actionLedingkart Meetup #1: Monolithic to microservices in action
Ledingkart Meetup #1: Monolithic to microservices in action
 
PyCONKE meetup 2019: Microservices
PyCONKE meetup 2019: MicroservicesPyCONKE meetup 2019: Microservices
PyCONKE meetup 2019: Microservices
 
apidays LIVE Paris - GraphQL meshes by Jens Neuse
apidays LIVE Paris - GraphQL meshes by Jens Neuseapidays LIVE Paris - GraphQL meshes by Jens Neuse
apidays LIVE Paris - GraphQL meshes by Jens Neuse
 
Microservices architecture ext
Microservices architecture extMicroservices architecture ext
Microservices architecture ext
 
Rez gateway - RezOS - innovate the future
Rez gateway - RezOS -   innovate the futureRez gateway - RezOS -   innovate the future
Rez gateway - RezOS - innovate the future
 
Rez gateway (RezOS) innovate the future
Rez gateway  (RezOS) innovate the futureRez gateway  (RezOS) innovate the future
Rez gateway (RezOS) innovate the future
 
Twelve-Factor application pattern with Spring Framework
Twelve-Factor application pattern with Spring FrameworkTwelve-Factor application pattern with Spring Framework
Twelve-Factor application pattern with Spring Framework
 
Challenges In Modern Application
Challenges In Modern ApplicationChallenges In Modern Application
Challenges In Modern Application
 
Changing Views on Integration (AUSOUG Webinar Series, May 2020)
Changing Views on Integration (AUSOUG Webinar Series, May 2020)Changing Views on Integration (AUSOUG Webinar Series, May 2020)
Changing Views on Integration (AUSOUG Webinar Series, May 2020)
 
MuleSoft Manchester Meetup #4 slides 11th February 2021
MuleSoft Manchester Meetup #4 slides 11th February 2021MuleSoft Manchester Meetup #4 slides 11th February 2021
MuleSoft Manchester Meetup #4 slides 11th February 2021
 
MuleSoft Meetup Adelaide 7th April 2021
MuleSoft Meetup Adelaide 7th April 2021MuleSoft Meetup Adelaide 7th April 2021
MuleSoft Meetup Adelaide 7th April 2021
 
Micro service architecture
Micro service architecture  Micro service architecture
Micro service architecture
 
Moving existing apps to the cloud
 Moving existing apps to the cloud Moving existing apps to the cloud
Moving existing apps to the cloud
 
Introduction to microservices
Introduction to microservicesIntroduction to microservices
Introduction to microservices
 
Lagom : Reactive microservice framework
Lagom : Reactive microservice frameworkLagom : Reactive microservice framework
Lagom : Reactive microservice framework
 
MuleSoft London Community October 2017 - Hybrid and SAP Integration
MuleSoft London Community October 2017 - Hybrid and SAP IntegrationMuleSoft London Community October 2017 - Hybrid and SAP Integration
MuleSoft London Community October 2017 - Hybrid and SAP Integration
 

Recently uploaded

Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticsKotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticscarlostorres15106
 
Key Features Of Token Development (1).pptx
Key  Features Of Token  Development (1).pptxKey  Features Of Token  Development (1).pptx
Key Features Of Token Development (1).pptxLBM Solutions
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreternaman860154
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitecturePixlogix Infotech
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slidespraypatel2
 
Azure Monitor & Application Insight to monitor Infrastructure & Application
Azure Monitor & Application Insight to monitor Infrastructure & ApplicationAzure Monitor & Application Insight to monitor Infrastructure & Application
Azure Monitor & Application Insight to monitor Infrastructure & ApplicationAndikSusilo4
 
Pigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping ElbowsPigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping ElbowsPigging Solutions
 
Snow Chain-Integrated Tire for a Safe Drive on Winter Roads
Snow Chain-Integrated Tire for a Safe Drive on Winter RoadsSnow Chain-Integrated Tire for a Safe Drive on Winter Roads
Snow Chain-Integrated Tire for a Safe Drive on Winter RoadsHyundai Motor Group
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking MenDelhi Call girls
 
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | DelhiFULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhisoniya singh
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationRidwan Fadjar
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxMalak Abu Hammad
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesSinan KOZAK
 
Install Stable Diffusion in windows machine
Install Stable Diffusion in windows machineInstall Stable Diffusion in windows machine
Install Stable Diffusion in windows machinePadma Pradeep
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking MenDelhi Call girls
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonetsnaman860154
 
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...HostedbyConfluent
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountPuma Security, LLC
 
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 3652toLead Limited
 

Recently uploaded (20)

Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticsKotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
 
Key Features Of Token Development (1).pptx
Key  Features Of Token  Development (1).pptxKey  Features Of Token  Development (1).pptx
Key Features Of Token Development (1).pptx
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreter
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC Architecture
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slides
 
Azure Monitor & Application Insight to monitor Infrastructure & Application
Azure Monitor & Application Insight to monitor Infrastructure & ApplicationAzure Monitor & Application Insight to monitor Infrastructure & Application
Azure Monitor & Application Insight to monitor Infrastructure & Application
 
Pigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping ElbowsPigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping Elbows
 
Snow Chain-Integrated Tire for a Safe Drive on Winter Roads
Snow Chain-Integrated Tire for a Safe Drive on Winter RoadsSnow Chain-Integrated Tire for a Safe Drive on Winter Roads
Snow Chain-Integrated Tire for a Safe Drive on Winter Roads
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men
 
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | DelhiFULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 Presentation
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptx
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen Frames
 
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptxE-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
 
Install Stable Diffusion in windows machine
Install Stable Diffusion in windows machineInstall Stable Diffusion in windows machine
Install Stable Diffusion in windows machine
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
 
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path Mount
 
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
 

How to move from Monolith to Microservice

  • 1. Prepared by @saflimbenly -2016Prepared by @saflimbenly -2016 Monolith to Microservices How to implement Application Modernization in 2016
  • 2. Prepared by @saflimbenly -2016 Monolith ● Simple to test ● Simple to deploy ● Scale by multiple copies ● ACID (Atomicity, Consistency, Isolation, Durability) ● Complex ● Slow down development ● Scale problem ● Reliability (memory leak, db lock) ● Hiring
  • 3. Prepared by @saflimbenly -2016 Microservices Split the application into smaller and interconnected services. ● Develop, Deploy, Scale Independently ● Domain-driven Design (Core / Process Service) ● Event-driven Data Management ● DB schema per service (loose coupling) ● Inter-process Communication (RPC, message Driven API) ● Determine the service size (How big is 1 service?) ● Distributed system (what IPC has to be used?) ● Partitioned DB architecture (ERD of the application) ● Testing, Deploy, Manage ● Change multiple Service (complex business process)
  • 4. Prepared by @saflimbenly -2016 Example of Microservices
  • 5. Prepared by @saflimbenly -2016 Microservices Principle ● Each Microservices Has Its Own Build ● Business Logic is Stateless ● Data Layer is Cached ● Separate Data Source ● Independently Deployable ● Fully Contained
  • 6. Prepared by @saflimbenly -2016 Microservices Best Practice ● Design for Automation (Continuous Delivery) ● Design for Failure ○ Service load balancing ○ Automation scaling ○ Retry on failure ○ Circuit breaker ○ Bulkhead ○ Timeouts ● Design for Data Separation ● Design for Integrity ○ Transaction ○ Read-Write ○ Event-driven Design ○ Transaction IDs ● Design for Performance ○ Load test ○ Technology ○ API Gateway & LB ○ Cache
  • 7. Prepared by @saflimbenly -2016 Migration Approaches Strangler PatternBig Bang
  • 8. Prepared by @saflimbenly -2016 Strategy 1 - Stop Digging ● The Law of Holes ● Anti-corruption Layer ● Domain-Driven Design
  • 9. Prepared by @saflimbenly -2016 Strategy 2 - Split Frontend and Backend ● Presentation Layer ● Business Logic Layer ● Data-Access Layer ● Using latest technology without hurting current stack ● Only provide API call from Backend
  • 10. Prepared by @saflimbenly -2016 Strategy 3 - Extract Services ● Prioritize which module to convert ● Paying “technical debt” one service at the time. Step 1
  • 11. Prepared by @saflimbenly -2016 Strategy 3 - Extract Services (Cont.) Step 2
  • 12. Prepared by @saflimbenly -2016 Architecture Overview ● One Service One Data Source ● Implement DDD ● Using CQRS / Event Sourcing pattern ● Each service component can be one containers ● API Gateway handle : request routing, composition, service discovery.
  • 13. Prepared by @saflimbenly -2016 How We Are Going To Do It ● Agile Scrum/Kanban ● Team can be change on each sprint/project. ● Every member can have a chance to involve in this process, depends on knowledge they have in particular module.
  • 14. Prepared by @saflimbenly -2016 API Gateway (In Progress) - Request routing - Composition - Protocol Transaction - Not “One-Size-Fit-All” but “One-Call-Serve- All” - Service Invocation - Service Discovery - Mismatch - Different protocols - Refactor
  • 15. Prepared by @saflimbenly -2016 Event-driven Data Management (In Progress) - NoSQL - ElasticSearch - Neo4j - Geo-location Preserve Atomicity - Publishing Event using Local Transaction - Mining a Database Transaction Log - Event Sourcing - Implement business transaction that maintain consistency across multiple services - Implement query to retrieve data from multiple services
  • 16. Prepared by @saflimbenly -2016 Cross-cutting Concerns (In Progress) ● Security ● Logging ● Health Checks ● Integration Testing
  • 17. Prepared by @saflimbenly -2016 Technology Stack Java EE and DDD : ● JAX-RS ● Stateless EJB ● JPA (Entities, Embeddable, EM) ● Websocket ● Concurrency Utilities ● Apache Kafka ● etc... DevOps, Crosscutting, Microservices : ● Git ● Docker / Dokku ● Jenkins ● Redis ● PostgreSQL ● NoSQL ● Swagger ● Logback ● etc...