Continuous Delivery profits from Micro Services - and the other way round. This presentation shows how the two technologies work together - and how Micro Services can be used to simplify the transition to Continuous Delivery.
13. Micro Services: Definition
• Small
• Independent deployment units
• i.e. processes
Eberhard Wolff - @ewolff
• Any technology
• Any infrastructure
Micro
Service
Server
Micro
Service
Server
15. Why Micro Services?
• Strong modularization
• i.e. no unwanted dependencies
• Choose best technology for each service
• Includes database etc
• Teams can deploy new features
• Completely independent
• Micro Service must provide meaningful
set of features
Eberhard Wolff - @ewolff
18. Continuous Delivery
Eberhard Wolff - @ewolff
• Automated provisioning
• Fast Feedback
• Tests, tests, tests…
• Feedback from production
• Monitoring
• Logs analysis
19. Why Continuous Delivery?
• Faster time to market
• i.e. can deploy changes quickly into
production
• Less risk
• Many tests
• Automation mean reproducible results
• Smaller deployments
Eberhard Wolff - @ewolff
23. Build Pipeline: Problems
• Complex infrastructure
• Huge database
• 3rd party integration
• Slow feedback
• Test everything for each commit
• Huge deployment unit
• Deployment slow
Eberhard Wolff - @ewolff
24. Eberhard Wolff - @ewolff
Micro Services
• Small independent deployment units
• E.g. interface backwards compatibility
• Otherwise Micro Services would need
to be deployed together
• Sensible set of features
• Business features should be deployed
independently
25. Eberhard Wolff - @ewolff
Micro Services
Order
ECommerce
System
3rd party
systems
Item
Customer
Database
27. Build Pipeline for
Micro Services
• Independent deployment
• Build pipeline per Micro Service
• Smaller
• Easier to set up
• Less features (3rd party systems)
• Faster Feedback: Less tests
Eberhard Wolff - @ewolff
28. Eberhard Wolff - @ewolff
Micro Services
Order
ECommerce
System
3rd party
systems
Item
Customer
Database
29. Micro Service & Databases
• Micro Services don’t share data
• i.e. database (schema) per server
Eberhard Wolff - @ewolff
• Easier schema migration
• Easier deployment
30. Micro Services Design
• System becomes a distributed system
Eberhard Wolff - @ewolff
• The network is not reliable
• Micro Services fail
• A failed Micro Services must not cause
other to fail
32. Eberhard Wolff - @ewolff
Resilience
A system
built out of unreliable
components
with resilience
is more robust.
33. Would you reboot
your database just
like that?
Eberhard Wolff - @ewolff
34. Amazon Reboot
• Amazon Cloud rebooted several
machines
• Netflix: video streaming
• Peak: 30% of internet traffic in the US
• 2700 database server
• 218 rebooted
• 22 not successful
• 0 downtime
Eberhard Wolff - @ewolff
35. Risk Mitigation in
Continuous Delivery
• Blue / Green Deployment
• Create complete cluster with new
release
• Test and only switch if OK
• Canary Releasing
• Release to a few nodes
• Rollback if needed
Eberhard Wolff - @ewolff
36. Micro Services:
Further Risk Mitigation
• Smaller deployment units
• Deployment Failure influences less
features
• Easier rollback / fixing
• Resilience: Other Micro Services
still operational
Eberhard Wolff - @ewolff
38. Micro Service & Servers
• Potentially different technology
stack per service
• Individual processes
• Each component has its own server
• …per stage in the pipeline
Eberhard Wolff - @ewolff
43. Eberhard Wolff - @ewolff
Micro Service
App +
App Server +
Database +
More infrastructure
Individual technology stack
44. Micro Services & Automation
• Infrastructure much more complex
• More servers
• More services
• Need to automate provisioning
• (Virtual) Servers
• Software
• Complete software stacks
Eberhard Wolff - @ewolff
45. Micro Services & Feedback:
Eberhard Wolff - @ewolff
Logs
• Simple grep on a log file not enough
• Too many servers
• Correlation across servers
• Centralized logging needed
46. Micro Services & Feedback:
Eberhard Wolff - @ewolff
Monitoring
• Just top on a server is not enough
• Too many servers
• Not just your application…
• …also database
• …other infrastructure
• Centralized monitoring needed
62. Migration to Micro Service
and Continuous Delivery
• Micro Services can be added to a
Monolith
• Might use different technologies
• Different way to handle legacy
applications
• Easier to create a Continuous
Delivery Pipeline for Micro Service
• But: Higher overall complexity
Eberhard Wolff - @ewolff