The Microservices journey from a startup perspective Susanne Kaiser CTO @suksr Just Software @JustSocialApps
Each journey is different “People try to copy Netflix, but they can only copy what they see. They copy the results, not the process.” Adrian Cockcroft, AWS VP Cloud Archtitect, former Netflix Chief Cloud Architect
The beginning … A monolith in every aspect One One team technology stack One collaboration product
After an evolving while … Productivity suffered New features released slowly Usability and UX suffered
Separate Collaboration Apps JUST CHAT JUST CONNECT Social Network Real-time collaboration JUST WIKI JUST DRIVE Knowledge Base Document Sharing JUST TASKS Task Management
Small, autonomous teams with well-defined responsibilities JUST CONNECT Social Network JUST CHAT Real-time collaboration JUST WIKI Knowledge Base JUST DRIVE Document Sharing JUST TASKS Task Management
In the long run ...
Looks easy at first glance ...
Microservices come with complexity Design for Failure Testing Monitoring Deployment Debugging Eventual consistency Skillset is different Authentication & Authorization Development environment
Challenges of transformation You still have to Transformation take care of your takes longer than existing system anticipated Core functionality All involved parties need to is hard to untangle agree and to be on board
Don't partition without a good reason.
How to start? ? ? ? ?
Key concepts of modelling Microservices Loose coupling between services High cohesion within a service
Identify Bounded Contexts “A specific responsibility [..] enforced with explicit boundaries” http://blog.sapiensworks.com/post/2012/04/17/DDD-The-Bounded-Context-Explained.aspx
Bounded Contexts = Collaboration Apps JUST CHAT JUST DRIVE JUST CONNECT JUST TASKS JUST WIKI Monolith
First approach as a co-existing service Monolith Web App JUST CHAT JUST DRIVE REST API JUST CONNECT r Message Broker e k o JUST DRIVE r B r Adapter e e g t p a a s s d e A M JUST TASKS JUST WIKI DB Adapter Message DB Adapter Broker
Heavy undertake if you do all at once New UI Maintain & run current system New data structure New technology Extend skillset
Split in steps – e.g. top down
Split in steps – e.g. top down Browser Monolith Web Client DB Adapter
Split in steps – Step 1) Extracting Web App Browser Monolith Web App Web Client Web Client REST Client REST API Business Logic DB Adapter
Split in steps – Step 2) Extracting Business Logic Browser Web App Monolith Web Client REST API REST Client REST API Business Logic Business Logic REST Client R E S T A P I DB Adapter DB Adapter
Split in steps – Step 3) Extracting Data Storage Browser Web App Monolith Web Client REST API REST Client REST API Business Logic Business Logic Message Broker Message Broker REST Client R Adapter E Adapter S T A P I DB Adapter DB Adapter Message Broker
Which one first? Changing Easy to extract frequently Different resource requirements
Stop feeding the monolith Monolith
Get your CI/CD pipeline ready + Commit Stage Unit Code Integration CDC Assemble Publish Compile Tests Analysis Tests Tests distribution binaries Retrieve Deploy Functional Deploy Deploy binaries binaries Test binaries binaries Acceptance Stage UAT Production Manually triggered
Testing - Consumer Driven Contract Tests with Pact Source: https://jaxenter.de/microservices-consumer-driven-contract-testing-mit-pact-20574
Deployment in a polyglot enviroment On-Premises Cloud Service Instance per Host Multiple Service Instances per Host/Process Each service instance runs in Efficient resource utilization complete isolation
Design for Failure Timeout-Handling Provide fallbacks Limit number of outstanding requests Circuit Breakers
Development environment Full access to the entire system
Summary Don't partition without a good reason Identify your bounded contexts Split in manageable steps Get your build and delivery pipeline ready It's not only a technical but also a cultural shift
… AND W/ MICROSERVISES !
THANK YOU! Susanne Kaiser CTO @suksr Just Software @JustSocialApps
Recommend
More recommend