SlideShare ist ein Scribd-Unternehmen logo
1 von 32
Downloaden Sie, um offline zu lesen
© Equal Experts UK Ltd 2015 1
Microservices
Scaling Development and Service
by Paulo Gaspar
© Equal Experts UK Ltd 2015 2
What are Microservices?
© Equal Experts UK Ltd 2015 3
Large(-ish) Systems
•  Ever worked on one?
•  Which roles did you play?
•  How do you rate its…
•  Knowledge sharing / communication?
•  Pace of progress? New technology adoption?
•  Ease of technical debt elimination?
•  Accountability (not throwing issues over the wall)?
•  Did your team feel they owned the project?
© Equal Experts UK Ltd 2015 4
Small Systems
•  Ever worked on one?
•  Which roles did you play?
•  How do you rate its…
•  Knowledge sharing / communication?
•  Pace of progress? New technology adoption?
•  Ease of technical debt elimination?
•  Accountability (not throwing issues over the wall)?
•  Did your team feel they owned the project?
© Equal Experts UK Ltd 2015 5
Fowler Description
§  The microservice architectural style is an approach to developing a single application as
a suite of small services, each running in its own process and communicating with
lightweight mechanisms, often an HTTP resource API. These services are built around
business capabilities and independently deployable by fully automated deployment
machinery. There is a bare minimum of centralized management of these services,
which may be written in different programming languages and use different data storage
technologies.
http://martinfowler.com/articles/microservices.html
© Equal Experts UK Ltd 2015 6
MY OWN EXPERIENCE
(A cautionary tale?)
© Equal Experts UK Ltd 2015 7
The First Time®!
•  Just because of Spring Boot
(and Spring Loaded!)
•  We loved deployments!
•  Naturally, services were split and kept being split by functionality
•  We had different load requirements per service…
•  We started everything by hand, with scripts
•  We looked at Docker and several tools
© Equal Experts UK Ltd 2015 8
2nd, with an experienced team...
First impressions
•  Very senior team
•  Agile, TDD, Reactive, Scala, Pairing, Q&A, …
•  So many services, and they run ok on my machine!
•  Infrastructure restrictions on used technologies
•  No management interference on technical decisions
•  Management SUPPORTS technical issue prioritization!
© Equal Experts UK Ltd 2015 9
2nd, with an experienced team...
Second impressions
•  Shocking: no Business Logic on Libraries!!!
•  Distributed computing like issues
(error propagation, latencies…)
•  Internal Open Source
© Equal Experts UK Ltd 2015 10
2nd, with an experienced team...
Second impressions
•  Something tribal about the developer team, like:
•  We would trigger a whole team impromptu meeting if we found a production problem
•  And we would do the same to take a structural decision about code we were working on
•  Devs would sometime work out of office hours,
but mostly monitoring!
•  Devs reported a large part of the production issues
•  A lot of importance was given to Devs feedback
© Equal Experts UK Ltd 2015 11
2nd, with an experienced team...
Contact with the other teams
•  Infrastructure teams would send us people to help us and doctrine us on the hows and
whys of their systems
•  We were supported into monitoring our services
•  There was an ongoing effort to allow us to deploy our own services
© Equal Experts UK Ltd 2015 12
2nd, with an experienced team...
The Big Picture
•  Did I tell you there were hundreds of developers on the whole project?
•  Was the management behaviour Microservice related?
•  Was the development team behaviour Microservice related?
•  Was the infrastructure teams behaviour Microservice related?
© Equal Experts UK Ltd 2015 13
2nd, with an experienced team...
The Big Picture
Ownership
Accountability
Trust
© Equal Experts UK Ltd 2015 14
3rd time is a charm?
•  Microservice wise, a less mature customer team
•  Moving functionality from a large monolithic system to Microservices
•  A colleague’s proposal:
•  Before / instead of migrating, just break the old system into Microservices!
© Equal Experts UK Ltd 2015 15
WHAT DO OTHERS SAY?
© Equal Experts UK Ltd 2015 16
Development Scalability
on large applications
•  Steeper learning curve
•  Development tools and containers get overloaded
=> slower development
•  Larger teams have higher communication costs / problems
•  Must rebuild and redeploy everything for any small change
•  Any change (functional or technologic) is harder and riskier
•  Riskier and expensive changes happen less frequently!
© Equal Experts UK Ltd 2015 17
Development Scalability
on Microservices
•  Services get developed and deployed independently
•  Smaller, simpler code bases
•  Easier to learn and faster to develop on
•  Less dependency hell
•  Faster + simpler build and deployment
•  Easier to compose and to replace
•  Smaller teams
•  Less communication paths, lower communication costs
•  Change is simpler and risks more isolated
© Equal Experts UK Ltd 2015 18
Is this SOA
•  “Traditional SOA” was dominated by vendors and the technologies they promoted
(e.g.: some people thought that SOA had to be done with SOAP)
•  Microservices grew from practical needs and concerns, with no vendor/technology ties
•  SOA done right?
© Equal Experts UK Ltd 2015 19
Historic Big Players
•  Amazon
•  Amazon Cloud
•  Amazon’s Two-Pizza Team Rule
http://blog.idonethis.com/two-pizza-team/
•  Netflix
•  http://netflix.github.io
© Equal Experts UK Ltd 2015 20
When you start
•  Start small
•  Learn the basics well and ASAP
•  Just the essential principles you need for your scale
•  …inclusive about REST, if you use it
•  …and CQRS (Command Query Responsibility Segregation)
•  Don’t be in a hurry to divide services
•  Take your time to learn each piece you add
•  Lear about the “new” types of error you are exposed to, like:
•  Fallacies of distributed computing
https://en.wikipedia.org/wiki/Fallacies_of_distributed_computing
© Equal Experts UK Ltd 2015 21
…remembering the falacies…
•  The network is reliable.
•  Latency is zero.
•  Bandwidth is infinite.
•  The network is secure.
•  Topology doesn't change.
•  There is one administrator.
•  Transport cost is zero.
•  The network is homogeneous.
© Equal Experts UK Ltd 2015 22
When you start
•  Brace for networking related problems
•  Latency across a call stack
•  Manage timeouts
•  Cascading failures
•  Circuit breakers, bulkheads, isolation
•  Start monitoring
•  Collect metrics
•  Good logs and a log repository
•  Tracing
© Equal Experts UK Ltd 2015 23
SOME STUDY REFERENCES…
© Equal Experts UK Ltd 2015 24
Reading material
•  Building Microservices, by Sam Newman
(O’REILLY)
•  http://microservices.io
•  Netflix stuff
•  http://netflix.github.io
•  Distributed computing
(search about these topics)
•  CAP Theorem (read the paper)
•  Eventual Consistency (read the Dynamo DB paper)
•  Idempotency
•  Consensus
•  Causality
© Equal Experts UK Ltd 2015 25
Microservice frameworks
•  Dropwizard
http://www.dropwizard.io
•  Spring Boot
http://projects.spring.io/spring-boot/
https://github.com/spring-projects/spring-loaded
https://spring.io/blog/2015/06/17/devtools-in-spring-boot-1-3
http://projects.spring.io/spring-hateoas/
•  Play Framework
https://www.playframework.com
•  Netflix Karyon
https://github.com/Netflix/karyon
© Equal Experts UK Ltd 2015 26
Monitoring
•  Metrics
https://dropwizard.github.io/metrics/
•  Grafana
http://grafana.org
•  ELK – ElasticSearch, LogStash, Kibana
https://www.elastic.co/webinars/introduction-elk-stack
•  Twitter Zipkin (tracing)
http://twitter.github.io/zipkin/
© Equal Experts UK Ltd 2015 27
Basic Resilience
•  Netflix stuff
(discovery, client side LB, circuit breakers)
•  http://netflix.github.io
•  http://cloud.spring.io/spring-cloud-netflix/
•  Spring Cloud
•  http://cloud.spring.io/
© Equal Experts UK Ltd 2015 28
Databases and Datastores
•  Service databases
(one instance/schema per service family)
•  Separated report database (usually relational)
•  Database variants
•  Relational, document based, key-value, etc.
•  Notable databases / data stores
•  MongoDB, PostgreSQL, Redis, ElasticSearch
•  http://projects.spring.io/spring-data/
© Equal Experts UK Ltd 2015 29
Messaging
•  Sophisticated Routing
RabbitMQ
https://www.rabbitmq.com
•  High volume
Apache Kafka
http://kafka.apache.org
https://github.com/spring-projects/spring-integration-kafka
© Equal Experts UK Ltd 2015 30
Others
•  Swagger
(service description)
http://swagger.io
•  NGINX
(networking infrastructure)
https://www.nginx.com
•  Zookeeper
(consensus, presence, other coordination)
http://zookeeper.apache.org
•  Docker
(virtualization)
https://www.docker.com
•  DEIS
(Docker based PaaS)
http://deis.io
© Equal Experts UK Ltd 2015 31
CI and Delivery + Security
•  There is so much to add about these themes!!!
© Equal Experts UK Ltd 2015 32
Thank you!

Weitere ähnliche Inhalte

Was ist angesagt?

Was ist angesagt? (20)

Learning from Learnings: Anatomy of Three Incidents
Learning from Learnings: Anatomy of Three IncidentsLearning from Learnings: Anatomy of Three Incidents
Learning from Learnings: Anatomy of Three Incidents
 
O'Reilly/Nginx 2016: "Continuous Delivery with Containers: The Trials and Tri...
O'Reilly/Nginx 2016: "Continuous Delivery with Containers: The Trials and Tri...O'Reilly/Nginx 2016: "Continuous Delivery with Containers: The Trials and Tri...
O'Reilly/Nginx 2016: "Continuous Delivery with Containers: The Trials and Tri...
 
Reactive Principles and Microservices
Reactive Principles and MicroservicesReactive Principles and Microservices
Reactive Principles and Microservices
 
Effective Microservices In a Data-centric World
Effective Microservices In a Data-centric WorldEffective Microservices In a Data-centric World
Effective Microservices In a Data-centric World
 
An End to End Stack for a Container Age - Continuous Delivery London 2016
An End to End Stack for a Container Age - Continuous Delivery London 2016An End to End Stack for a Container Age - Continuous Delivery London 2016
An End to End Stack for a Container Age - Continuous Delivery London 2016
 
The seven more deadly sins of microservices final
The seven more deadly sins of microservices finalThe seven more deadly sins of microservices final
The seven more deadly sins of microservices final
 
DevOps Ground Zero
DevOps Ground ZeroDevOps Ground Zero
DevOps Ground Zero
 
DevoxxUK 2014 "Moving to a DevOps Mode: Easy, Hard, or Just Plain Terrifying?"
DevoxxUK 2014 "Moving to a DevOps Mode: Easy, Hard, or Just Plain Terrifying?"DevoxxUK 2014 "Moving to a DevOps Mode: Easy, Hard, or Just Plain Terrifying?"
DevoxxUK 2014 "Moving to a DevOps Mode: Easy, Hard, or Just Plain Terrifying?"
 
Haufe #msaday: "Building a Microservice Ecosystem"
Haufe #msaday: "Building a Microservice Ecosystem"Haufe #msaday: "Building a Microservice Ecosystem"
Haufe #msaday: "Building a Microservice Ecosystem"
 
LJC 05/14 "Cloud Developer's DHARMA"
LJC 05/14 "Cloud Developer's DHARMA"LJC 05/14 "Cloud Developer's DHARMA"
LJC 05/14 "Cloud Developer's DHARMA"
 
LJC: "Chuck Norris Doesn't Do DevOps...but Java developers might benefit"
LJC: "Chuck Norris Doesn't Do DevOps...but Java developers might benefit"LJC: "Chuck Norris Doesn't Do DevOps...but Java developers might benefit"
LJC: "Chuck Norris Doesn't Do DevOps...but Java developers might benefit"
 
Open Source and Content Management (+audio)
Open Source and Content Management (+audio)Open Source and Content Management (+audio)
Open Source and Content Management (+audio)
 
SOASTA mPulse update webinar
SOASTA mPulse update webinarSOASTA mPulse update webinar
SOASTA mPulse update webinar
 
Devops Recto-Verso @ DevoxxMA
Devops Recto-Verso @ DevoxxMADevops Recto-Verso @ DevoxxMA
Devops Recto-Verso @ DevoxxMA
 
DevOps Requires Agility
DevOps Requires AgilityDevOps Requires Agility
DevOps Requires Agility
 
The seven deadly sins of microservices
The seven deadly sins of microservicesThe seven deadly sins of microservices
The seven deadly sins of microservices
 
DOES15 - Jim Stoneham - Getting Faster Answers at Yahoo Answers
DOES15 - Jim Stoneham - Getting Faster Answers at Yahoo AnswersDOES15 - Jim Stoneham - Getting Faster Answers at Yahoo Answers
DOES15 - Jim Stoneham - Getting Faster Answers at Yahoo Answers
 
JavaOne 2014: Cloud Developer's DHARMA: Redefining 'done' for Cloud applications
JavaOne 2014: Cloud Developer's DHARMA: Redefining 'done' for Cloud applicationsJavaOne 2014: Cloud Developer's DHARMA: Redefining 'done' for Cloud applications
JavaOne 2014: Cloud Developer's DHARMA: Redefining 'done' for Cloud applications
 
Continuous Delivery antipatterns from the wild - Matthew Skelton - Continuous...
Continuous Delivery antipatterns from the wild - Matthew Skelton - Continuous...Continuous Delivery antipatterns from the wild - Matthew Skelton - Continuous...
Continuous Delivery antipatterns from the wild - Matthew Skelton - Continuous...
 
Managing Data at Scale - Microservices and Events
Managing Data at Scale - Microservices and EventsManaging Data at Scale - Microservices and Events
Managing Data at Scale - Microservices and Events
 

Andere mochten auch

Near shoring in Portugal
Near shoring in Portugal Near shoring in Portugal
Near shoring in Portugal
malduarte
 
Introduction to Web Application Clustering
Introduction to Web Application ClusteringIntroduction to Web Application Clustering
Introduction to Web Application Clustering
Piyush Katariya
 
Brand managers drumoct1st2010
Brand managers drumoct1st2010Brand managers drumoct1st2010
Brand managers drumoct1st2010
Adam Mitchell
 

Andere mochten auch (18)

Anti-Usability and UX - Simon Bostock, GOTO Berlin 2014
 Anti-Usability and UX - Simon Bostock, GOTO Berlin 2014 Anti-Usability and UX - Simon Bostock, GOTO Berlin 2014
Anti-Usability and UX - Simon Bostock, GOTO Berlin 2014
 
Nuno
NunoNuno
Nuno
 
Practical guide to building public APIs
Practical guide to building public APIsPractical guide to building public APIs
Practical guide to building public APIs
 
KISS me quickly: The battle against complexity
KISS me quickly: The battle against complexityKISS me quickly: The battle against complexity
KISS me quickly: The battle against complexity
 
Lyndsay Prewer - Smoothing the continuous delivery path - a tale of two teams
Lyndsay Prewer - Smoothing the continuous delivery path - a tale of two teamsLyndsay Prewer - Smoothing the continuous delivery path - a tale of two teams
Lyndsay Prewer - Smoothing the continuous delivery path - a tale of two teams
 
Tesi tap di giacomo pistelli
Tesi tap di giacomo pistelliTesi tap di giacomo pistelli
Tesi tap di giacomo pistelli
 
Near shoring in Portugal
Near shoring in Portugal Near shoring in Portugal
Near shoring in Portugal
 
Yolk Recruitment HR Insights - Age Discrimination 10 Years On
Yolk Recruitment HR Insights - Age Discrimination 10 Years OnYolk Recruitment HR Insights - Age Discrimination 10 Years On
Yolk Recruitment HR Insights - Age Discrimination 10 Years On
 
AML and OFAC Compliance for the Insurance Industry - Conference Materials
AML and OFAC Compliance for the Insurance Industry - Conference MaterialsAML and OFAC Compliance for the Insurance Industry - Conference Materials
AML and OFAC Compliance for the Insurance Industry - Conference Materials
 
Deloitte Technology Fast 500 EMEA 2013 Ranking
Deloitte Technology Fast 500 EMEA 2013 RankingDeloitte Technology Fast 500 EMEA 2013 Ranking
Deloitte Technology Fast 500 EMEA 2013 Ranking
 
Introduction to Web Application Clustering
Introduction to Web Application ClusteringIntroduction to Web Application Clustering
Introduction to Web Application Clustering
 
Us sanctions eu_sanctions_expended_and_prolonged
Us sanctions eu_sanctions_expended_and_prolongedUs sanctions eu_sanctions_expended_and_prolonged
Us sanctions eu_sanctions_expended_and_prolonged
 
Microservices
MicroservicesMicroservices
Microservices
 
Brand managers drumoct1st2010
Brand managers drumoct1st2010Brand managers drumoct1st2010
Brand managers drumoct1st2010
 
Riac annual report_2012
Riac annual report_2012Riac annual report_2012
Riac annual report_2012
 
Coface CEE Top 500 Ranking August 2015
Coface CEE Top 500 Ranking August 2015Coface CEE Top 500 Ranking August 2015
Coface CEE Top 500 Ranking August 2015
 
5 Golden Rules to Building APIs
5 Golden Rules to Building APIs5 Golden Rules to Building APIs
5 Golden Rules to Building APIs
 
Mobile Network Infrastructure Sharing - Industry Overview & Coleago's Approach
Mobile Network Infrastructure Sharing - Industry Overview & Coleago's ApproachMobile Network Infrastructure Sharing - Industry Overview & Coleago's Approach
Mobile Network Infrastructure Sharing - Industry Overview & Coleago's Approach
 

Ähnlich wie Microservices - Scaling Development and Service

AWS Innovate: Smaller IS Better – Exploiting Microservices on AWS, Craig Dickson
AWS Innovate: Smaller IS Better – Exploiting Microservices on AWS, Craig DicksonAWS Innovate: Smaller IS Better – Exploiting Microservices on AWS, Craig Dickson
AWS Innovate: Smaller IS Better – Exploiting Microservices on AWS, Craig Dickson
Amazon Web Services Korea
 
cloud session uklug
cloud session uklugcloud session uklug
cloud session uklug
dominion
 

Ähnlich wie Microservices - Scaling Development and Service (20)

Serverless Toronto helps Startups
Serverless Toronto helps StartupsServerless Toronto helps Startups
Serverless Toronto helps Startups
 
Things I wish I'd known before I started with Microservices - GOTO Amsterdam ...
Things I wish I'd known before I started with Microservices - GOTO Amsterdam ...Things I wish I'd known before I started with Microservices - GOTO Amsterdam ...
Things I wish I'd known before I started with Microservices - GOTO Amsterdam ...
 
(SPOT205) 5 Lessons for Managing Massive IT Transformation Projects
(SPOT205) 5 Lessons for Managing Massive IT Transformation Projects(SPOT205) 5 Lessons for Managing Massive IT Transformation Projects
(SPOT205) 5 Lessons for Managing Massive IT Transformation Projects
 
Get Loose! Microservices and Loosely Coupled Architectures
Get Loose! Microservices and Loosely Coupled ArchitecturesGet Loose! Microservices and Loosely Coupled Architectures
Get Loose! Microservices and Loosely Coupled Architectures
 
Get Loose! Microservices and Loosely Coupled Architectures
Get Loose! Microservices and Loosely Coupled Architectures Get Loose! Microservices and Loosely Coupled Architectures
Get Loose! Microservices and Loosely Coupled Architectures
 
OpenStack in the Enterprise - NJ VMUG June 9, 2015 - Melissa Palmer
OpenStack in the Enterprise - NJ VMUG June 9, 2015 - Melissa PalmerOpenStack in the Enterprise - NJ VMUG June 9, 2015 - Melissa Palmer
OpenStack in the Enterprise - NJ VMUG June 9, 2015 - Melissa Palmer
 
QCon 2015 - Microservices Track Notes
QCon 2015 - Microservices Track Notes QCon 2015 - Microservices Track Notes
QCon 2015 - Microservices Track Notes
 
Changing the Game with Cloud, Microservices, and DevOps
Changing the Game with Cloud, Microservices, and DevOps Changing the Game with Cloud, Microservices, and DevOps
Changing the Game with Cloud, Microservices, and DevOps
 
DOES16 London - Jonathan Fletcher - Re-imagining Hiscox IT: A DevOps Story
DOES16 London - Jonathan Fletcher - Re-imagining Hiscox IT: A DevOps StoryDOES16 London - Jonathan Fletcher - Re-imagining Hiscox IT: A DevOps Story
DOES16 London - Jonathan Fletcher - Re-imagining Hiscox IT: A DevOps Story
 
AWS Summit Auckland - Smaller is Better - Microservices on AWS
AWS Summit Auckland - Smaller is Better - Microservices on AWSAWS Summit Auckland - Smaller is Better - Microservices on AWS
AWS Summit Auckland - Smaller is Better - Microservices on AWS
 
Reactive Micro Services with Java seminar
Reactive Micro Services with Java seminarReactive Micro Services with Java seminar
Reactive Micro Services with Java seminar
 
Microservices: Yes or not?
Microservices: Yes or not?Microservices: Yes or not?
Microservices: Yes or not?
 
Chris Munns, DevOps @ Amazon: Microservices, 2 Pizza Teams, & 50 Million Depl...
Chris Munns, DevOps @ Amazon: Microservices, 2 Pizza Teams, & 50 Million Depl...Chris Munns, DevOps @ Amazon: Microservices, 2 Pizza Teams, & 50 Million Depl...
Chris Munns, DevOps @ Amazon: Microservices, 2 Pizza Teams, & 50 Million Depl...
 
AWS Community Day: From Monolith to Microservices - What Could Go Wrong?
AWS Community Day: From Monolith to Microservices - What Could Go Wrong?AWS Community Day: From Monolith to Microservices - What Could Go Wrong?
AWS Community Day: From Monolith to Microservices - What Could Go Wrong?
 
AWS Innovate: Smaller IS Better – Exploiting Microservices on AWS, Craig Dickson
AWS Innovate: Smaller IS Better – Exploiting Microservices on AWS, Craig DicksonAWS Innovate: Smaller IS Better – Exploiting Microservices on AWS, Craig Dickson
AWS Innovate: Smaller IS Better – Exploiting Microservices on AWS, Craig Dickson
 
cloud session uklug
cloud session uklugcloud session uklug
cloud session uklug
 
Practical Microservice Architecture (edition 2022).pdf
Practical Microservice Architecture (edition 2022).pdfPractical Microservice Architecture (edition 2022).pdf
Practical Microservice Architecture (edition 2022).pdf
 
Minimum Viable Architecture - Good Enough is Good Enough
Minimum Viable Architecture - Good Enough is Good EnoughMinimum Viable Architecture - Good Enough is Good Enough
Minimum Viable Architecture - Good Enough is Good Enough
 
Why to Cloud Native
Why to Cloud NativeWhy to Cloud Native
Why to Cloud Native
 
Minimal Viable Architecture - Silicon Slopes 2020
Minimal Viable Architecture - Silicon Slopes 2020Minimal Viable Architecture - Silicon Slopes 2020
Minimal Viable Architecture - Silicon Slopes 2020
 

Kürzlich hochgeladen

%+27788225528 love spells in Boston Psychic Readings, Attraction spells,Bring...
%+27788225528 love spells in Boston Psychic Readings, Attraction spells,Bring...%+27788225528 love spells in Boston Psychic Readings, Attraction spells,Bring...
%+27788225528 love spells in Boston Psychic Readings, Attraction spells,Bring...
masabamasaba
 
%+27788225528 love spells in new york Psychic Readings, Attraction spells,Bri...
%+27788225528 love spells in new york Psychic Readings, Attraction spells,Bri...%+27788225528 love spells in new york Psychic Readings, Attraction spells,Bri...
%+27788225528 love spells in new york Psychic Readings, Attraction spells,Bri...
masabamasaba
 
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
Health
 
Large-scale Logging Made Easy: Meetup at Deutsche Bank 2024
Large-scale Logging Made Easy: Meetup at Deutsche Bank 2024Large-scale Logging Made Easy: Meetup at Deutsche Bank 2024
Large-scale Logging Made Easy: Meetup at Deutsche Bank 2024
VictoriaMetrics
 

Kürzlich hochgeladen (20)

WSO2Con2024 - WSO2's IAM Vision: Identity-Led Digital Transformation
WSO2Con2024 - WSO2's IAM Vision: Identity-Led Digital TransformationWSO2Con2024 - WSO2's IAM Vision: Identity-Led Digital Transformation
WSO2Con2024 - WSO2's IAM Vision: Identity-Led Digital Transformation
 
%in Midrand+277-882-255-28 abortion pills for sale in midrand
%in Midrand+277-882-255-28 abortion pills for sale in midrand%in Midrand+277-882-255-28 abortion pills for sale in midrand
%in Midrand+277-882-255-28 abortion pills for sale in midrand
 
OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...
OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...
OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...
 
%+27788225528 love spells in Boston Psychic Readings, Attraction spells,Bring...
%+27788225528 love spells in Boston Psychic Readings, Attraction spells,Bring...%+27788225528 love spells in Boston Psychic Readings, Attraction spells,Bring...
%+27788225528 love spells in Boston Psychic Readings, Attraction spells,Bring...
 
Architecture decision records - How not to get lost in the past
Architecture decision records - How not to get lost in the pastArchitecture decision records - How not to get lost in the past
Architecture decision records - How not to get lost in the past
 
Microsoft AI Transformation Partner Playbook.pdf
Microsoft AI Transformation Partner Playbook.pdfMicrosoft AI Transformation Partner Playbook.pdf
Microsoft AI Transformation Partner Playbook.pdf
 
%in Harare+277-882-255-28 abortion pills for sale in Harare
%in Harare+277-882-255-28 abortion pills for sale in Harare%in Harare+277-882-255-28 abortion pills for sale in Harare
%in Harare+277-882-255-28 abortion pills for sale in Harare
 
Announcing Codolex 2.0 from GDK Software
Announcing Codolex 2.0 from GDK SoftwareAnnouncing Codolex 2.0 from GDK Software
Announcing Codolex 2.0 from GDK Software
 
Payment Gateway Testing Simplified_ A Step-by-Step Guide for Beginners.pdf
Payment Gateway Testing Simplified_ A Step-by-Step Guide for Beginners.pdfPayment Gateway Testing Simplified_ A Step-by-Step Guide for Beginners.pdf
Payment Gateway Testing Simplified_ A Step-by-Step Guide for Beginners.pdf
 
%in Hazyview+277-882-255-28 abortion pills for sale in Hazyview
%in Hazyview+277-882-255-28 abortion pills for sale in Hazyview%in Hazyview+277-882-255-28 abortion pills for sale in Hazyview
%in Hazyview+277-882-255-28 abortion pills for sale in Hazyview
 
Direct Style Effect Systems - The Print[A] Example - A Comprehension Aid
Direct Style Effect Systems -The Print[A] Example- A Comprehension AidDirect Style Effect Systems -The Print[A] Example- A Comprehension Aid
Direct Style Effect Systems - The Print[A] Example - A Comprehension Aid
 
%+27788225528 love spells in new york Psychic Readings, Attraction spells,Bri...
%+27788225528 love spells in new york Psychic Readings, Attraction spells,Bri...%+27788225528 love spells in new york Psychic Readings, Attraction spells,Bri...
%+27788225528 love spells in new york Psychic Readings, Attraction spells,Bri...
 
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
 
%in tembisa+277-882-255-28 abortion pills for sale in tembisa
%in tembisa+277-882-255-28 abortion pills for sale in tembisa%in tembisa+277-882-255-28 abortion pills for sale in tembisa
%in tembisa+277-882-255-28 abortion pills for sale in tembisa
 
W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...
W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...
W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...
 
Large-scale Logging Made Easy: Meetup at Deutsche Bank 2024
Large-scale Logging Made Easy: Meetup at Deutsche Bank 2024Large-scale Logging Made Easy: Meetup at Deutsche Bank 2024
Large-scale Logging Made Easy: Meetup at Deutsche Bank 2024
 
%in kaalfontein+277-882-255-28 abortion pills for sale in kaalfontein
%in kaalfontein+277-882-255-28 abortion pills for sale in kaalfontein%in kaalfontein+277-882-255-28 abortion pills for sale in kaalfontein
%in kaalfontein+277-882-255-28 abortion pills for sale in kaalfontein
 
AI & Machine Learning Presentation Template
AI & Machine Learning Presentation TemplateAI & Machine Learning Presentation Template
AI & Machine Learning Presentation Template
 
%in Bahrain+277-882-255-28 abortion pills for sale in Bahrain
%in Bahrain+277-882-255-28 abortion pills for sale in Bahrain%in Bahrain+277-882-255-28 abortion pills for sale in Bahrain
%in Bahrain+277-882-255-28 abortion pills for sale in Bahrain
 
Software Quality Assurance Interview Questions
Software Quality Assurance Interview QuestionsSoftware Quality Assurance Interview Questions
Software Quality Assurance Interview Questions
 

Microservices - Scaling Development and Service

  • 1. © Equal Experts UK Ltd 2015 1 Microservices Scaling Development and Service by Paulo Gaspar
  • 2. © Equal Experts UK Ltd 2015 2 What are Microservices?
  • 3. © Equal Experts UK Ltd 2015 3 Large(-ish) Systems •  Ever worked on one? •  Which roles did you play? •  How do you rate its… •  Knowledge sharing / communication? •  Pace of progress? New technology adoption? •  Ease of technical debt elimination? •  Accountability (not throwing issues over the wall)? •  Did your team feel they owned the project?
  • 4. © Equal Experts UK Ltd 2015 4 Small Systems •  Ever worked on one? •  Which roles did you play? •  How do you rate its… •  Knowledge sharing / communication? •  Pace of progress? New technology adoption? •  Ease of technical debt elimination? •  Accountability (not throwing issues over the wall)? •  Did your team feel they owned the project?
  • 5. © Equal Experts UK Ltd 2015 5 Fowler Description §  The microservice architectural style is an approach to developing a single application as a suite of small services, each running in its own process and communicating with lightweight mechanisms, often an HTTP resource API. These services are built around business capabilities and independently deployable by fully automated deployment machinery. There is a bare minimum of centralized management of these services, which may be written in different programming languages and use different data storage technologies. http://martinfowler.com/articles/microservices.html
  • 6. © Equal Experts UK Ltd 2015 6 MY OWN EXPERIENCE (A cautionary tale?)
  • 7. © Equal Experts UK Ltd 2015 7 The First Time®! •  Just because of Spring Boot (and Spring Loaded!) •  We loved deployments! •  Naturally, services were split and kept being split by functionality •  We had different load requirements per service… •  We started everything by hand, with scripts •  We looked at Docker and several tools
  • 8. © Equal Experts UK Ltd 2015 8 2nd, with an experienced team... First impressions •  Very senior team •  Agile, TDD, Reactive, Scala, Pairing, Q&A, … •  So many services, and they run ok on my machine! •  Infrastructure restrictions on used technologies •  No management interference on technical decisions •  Management SUPPORTS technical issue prioritization!
  • 9. © Equal Experts UK Ltd 2015 9 2nd, with an experienced team... Second impressions •  Shocking: no Business Logic on Libraries!!! •  Distributed computing like issues (error propagation, latencies…) •  Internal Open Source
  • 10. © Equal Experts UK Ltd 2015 10 2nd, with an experienced team... Second impressions •  Something tribal about the developer team, like: •  We would trigger a whole team impromptu meeting if we found a production problem •  And we would do the same to take a structural decision about code we were working on •  Devs would sometime work out of office hours, but mostly monitoring! •  Devs reported a large part of the production issues •  A lot of importance was given to Devs feedback
  • 11. © Equal Experts UK Ltd 2015 11 2nd, with an experienced team... Contact with the other teams •  Infrastructure teams would send us people to help us and doctrine us on the hows and whys of their systems •  We were supported into monitoring our services •  There was an ongoing effort to allow us to deploy our own services
  • 12. © Equal Experts UK Ltd 2015 12 2nd, with an experienced team... The Big Picture •  Did I tell you there were hundreds of developers on the whole project? •  Was the management behaviour Microservice related? •  Was the development team behaviour Microservice related? •  Was the infrastructure teams behaviour Microservice related?
  • 13. © Equal Experts UK Ltd 2015 13 2nd, with an experienced team... The Big Picture Ownership Accountability Trust
  • 14. © Equal Experts UK Ltd 2015 14 3rd time is a charm? •  Microservice wise, a less mature customer team •  Moving functionality from a large monolithic system to Microservices •  A colleague’s proposal: •  Before / instead of migrating, just break the old system into Microservices!
  • 15. © Equal Experts UK Ltd 2015 15 WHAT DO OTHERS SAY?
  • 16. © Equal Experts UK Ltd 2015 16 Development Scalability on large applications •  Steeper learning curve •  Development tools and containers get overloaded => slower development •  Larger teams have higher communication costs / problems •  Must rebuild and redeploy everything for any small change •  Any change (functional or technologic) is harder and riskier •  Riskier and expensive changes happen less frequently!
  • 17. © Equal Experts UK Ltd 2015 17 Development Scalability on Microservices •  Services get developed and deployed independently •  Smaller, simpler code bases •  Easier to learn and faster to develop on •  Less dependency hell •  Faster + simpler build and deployment •  Easier to compose and to replace •  Smaller teams •  Less communication paths, lower communication costs •  Change is simpler and risks more isolated
  • 18. © Equal Experts UK Ltd 2015 18 Is this SOA •  “Traditional SOA” was dominated by vendors and the technologies they promoted (e.g.: some people thought that SOA had to be done with SOAP) •  Microservices grew from practical needs and concerns, with no vendor/technology ties •  SOA done right?
  • 19. © Equal Experts UK Ltd 2015 19 Historic Big Players •  Amazon •  Amazon Cloud •  Amazon’s Two-Pizza Team Rule http://blog.idonethis.com/two-pizza-team/ •  Netflix •  http://netflix.github.io
  • 20. © Equal Experts UK Ltd 2015 20 When you start •  Start small •  Learn the basics well and ASAP •  Just the essential principles you need for your scale •  …inclusive about REST, if you use it •  …and CQRS (Command Query Responsibility Segregation) •  Don’t be in a hurry to divide services •  Take your time to learn each piece you add •  Lear about the “new” types of error you are exposed to, like: •  Fallacies of distributed computing https://en.wikipedia.org/wiki/Fallacies_of_distributed_computing
  • 21. © Equal Experts UK Ltd 2015 21 …remembering the falacies… •  The network is reliable. •  Latency is zero. •  Bandwidth is infinite. •  The network is secure. •  Topology doesn't change. •  There is one administrator. •  Transport cost is zero. •  The network is homogeneous.
  • 22. © Equal Experts UK Ltd 2015 22 When you start •  Brace for networking related problems •  Latency across a call stack •  Manage timeouts •  Cascading failures •  Circuit breakers, bulkheads, isolation •  Start monitoring •  Collect metrics •  Good logs and a log repository •  Tracing
  • 23. © Equal Experts UK Ltd 2015 23 SOME STUDY REFERENCES…
  • 24. © Equal Experts UK Ltd 2015 24 Reading material •  Building Microservices, by Sam Newman (O’REILLY) •  http://microservices.io •  Netflix stuff •  http://netflix.github.io •  Distributed computing (search about these topics) •  CAP Theorem (read the paper) •  Eventual Consistency (read the Dynamo DB paper) •  Idempotency •  Consensus •  Causality
  • 25. © Equal Experts UK Ltd 2015 25 Microservice frameworks •  Dropwizard http://www.dropwizard.io •  Spring Boot http://projects.spring.io/spring-boot/ https://github.com/spring-projects/spring-loaded https://spring.io/blog/2015/06/17/devtools-in-spring-boot-1-3 http://projects.spring.io/spring-hateoas/ •  Play Framework https://www.playframework.com •  Netflix Karyon https://github.com/Netflix/karyon
  • 26. © Equal Experts UK Ltd 2015 26 Monitoring •  Metrics https://dropwizard.github.io/metrics/ •  Grafana http://grafana.org •  ELK – ElasticSearch, LogStash, Kibana https://www.elastic.co/webinars/introduction-elk-stack •  Twitter Zipkin (tracing) http://twitter.github.io/zipkin/
  • 27. © Equal Experts UK Ltd 2015 27 Basic Resilience •  Netflix stuff (discovery, client side LB, circuit breakers) •  http://netflix.github.io •  http://cloud.spring.io/spring-cloud-netflix/ •  Spring Cloud •  http://cloud.spring.io/
  • 28. © Equal Experts UK Ltd 2015 28 Databases and Datastores •  Service databases (one instance/schema per service family) •  Separated report database (usually relational) •  Database variants •  Relational, document based, key-value, etc. •  Notable databases / data stores •  MongoDB, PostgreSQL, Redis, ElasticSearch •  http://projects.spring.io/spring-data/
  • 29. © Equal Experts UK Ltd 2015 29 Messaging •  Sophisticated Routing RabbitMQ https://www.rabbitmq.com •  High volume Apache Kafka http://kafka.apache.org https://github.com/spring-projects/spring-integration-kafka
  • 30. © Equal Experts UK Ltd 2015 30 Others •  Swagger (service description) http://swagger.io •  NGINX (networking infrastructure) https://www.nginx.com •  Zookeeper (consensus, presence, other coordination) http://zookeeper.apache.org •  Docker (virtualization) https://www.docker.com •  DEIS (Docker based PaaS) http://deis.io
  • 31. © Equal Experts UK Ltd 2015 31 CI and Delivery + Security •  There is so much to add about these themes!!!
  • 32. © Equal Experts UK Ltd 2015 32 Thank you!