eat your microservices elephant one bite at a time
TRANSCRIPT
![Page 1: Eat Your Microservices Elephant One Bite at a Time](https://reader031.vdocument.in/reader031/viewer/2022030304/587a0ae51a28ab01268b69dd/html5/thumbnails/1.jpg)
© 2015 Akana., Inc All Rights Reserved. Powering the API Economy
MicroservicesWhat, Why, & How?
![Page 2: Eat Your Microservices Elephant One Bite at a Time](https://reader031.vdocument.in/reader031/viewer/2022030304/587a0ae51a28ab01268b69dd/html5/thumbnails/2.jpg)
© 2015 Akana., Inc All Rights Reserved. Powering the API Economy
What are Microservices?
• Microservices are a new way to build applications by breaking them up into small, independent, individual services
• No specific language• No heavy middleware (Websphere, Tibco, Oracle are all scrambling)• Mostly open-source
Loosely coupled service oriented architecture with bounded contexts -‐ Adrian Cockcroft
Small autonomous services that work together -‐ Sam Newman
![Page 3: Eat Your Microservices Elephant One Bite at a Time](https://reader031.vdocument.in/reader031/viewer/2022030304/587a0ae51a28ab01268b69dd/html5/thumbnails/3.jpg)
© 2015 Akana., Inc All Rights Reserved. Powering the API Economy
Pivotal/Netflix Microservices Architecture
![Page 4: Eat Your Microservices Elephant One Bite at a Time](https://reader031.vdocument.in/reader031/viewer/2022030304/587a0ae51a28ab01268b69dd/html5/thumbnails/4.jpg)
© 2015 Akana., Inc All Rights Reserved. Powering the API Economy
What defines a Microservice?
SOA + DevOps + Containers
![Page 5: Eat Your Microservices Elephant One Bite at a Time](https://reader031.vdocument.in/reader031/viewer/2022030304/587a0ae51a28ab01268b69dd/html5/thumbnails/5.jpg)
© 2015 Akana., Inc All Rights Reserved. Powering the API Economy
SOA vs SOA• Vendor-driven SOA gave us SOAP and ESBs• Microservices are a reaffirmation of SOA principles and a reaction to
vendor-driven SOA– dovetail in agile– dovetail in devops– dovetail in domain-driven design / BASE
• Microservices is unabashedly anti ESB
![Page 6: Eat Your Microservices Elephant One Bite at a Time](https://reader031.vdocument.in/reader031/viewer/2022030304/587a0ae51a28ab01268b69dd/html5/thumbnails/6.jpg)
© 2015 Akana., Inc All Rights Reserved. Powering the API Economy
What is DevOps?• The developer interacts with the infrastructure directly• Need fewer Operations staff – saves money• Increases agility by removing roadblocks
Develop' Test' UAT' Operate'
IDE$ Build$Tools$ Test$Suite$
Dev$Cloud$
Blueprint*
Web$Servers$App$
Servers$
Database$Servers$
Load$Balancer4$
Firewall$
Master$ Slave$
QA$Cloud$
Blueprint*
Web$Servers$App$
Servers$
Database$Servers$
Load$Balancer4$
Firewall$
Master$ Slave$
Load$Balancer$
Release$Management$
Blueprint*Web$Servers$
App$Servers$
Database$Servers$
Load$Balancer$
Firewall$
Master$ Slave$
Ready$for$Produc;on$
Common$Applica;on$Pla?orm$IT'Opera1ons'
![Page 7: Eat Your Microservices Elephant One Bite at a Time](https://reader031.vdocument.in/reader031/viewer/2022030304/587a0ae51a28ab01268b69dd/html5/thumbnails/7.jpg)
© 2015 Akana., Inc All Rights Reserved. Powering the API Economy
What is Containerization?
• Easier to use• More efficient• Smaller – hence
suited to Microservices
![Page 8: Eat Your Microservices Elephant One Bite at a Time](https://reader031.vdocument.in/reader031/viewer/2022030304/587a0ae51a28ab01268b69dd/html5/thumbnails/8.jpg)
© 2015 Akana., Inc All Rights Reserved. Powering the API Economy
Microservices Architecture• Been in use for a few years - Netflix, Gilt, Pivotal - term shows up in linux
microkernel discussions (1992)• Principles+ documented by Fowler & Lewis 03/2014 :
http://martinfowler.com/articles/microservices.html• Architecture - tradeoffs and capabilities• SOA vs. SOA (vendor-driven vs. microservices)
– Drivers: Scalability, Conway’s Law, Composition of focused services, agility of development frameworks (spring, ror, node, etc.)
![Page 9: Eat Your Microservices Elephant One Bite at a Time](https://reader031.vdocument.in/reader031/viewer/2022030304/587a0ae51a28ab01268b69dd/html5/thumbnails/9.jpg)
© 2015 Akana., Inc All Rights Reserved. Powering the API Economy
Microservices Principles1. Componentization via services [best technology for the job, common interface
(restish)]2. Organized around Business Capabilities3. Products not Projects [Conway’s law of organizational slippery slope]4. Smart endpoints dumb pipes [choreography vs. orchestration; choreographer
leads]5. Decentralized Governance [built into the service - share useful patterns via
libraries; less overhead; consumer-focused service contracts]6. Decentralized Data Management [domain driven design bounded context, etc.]7. Infrastructure Automation8. Design for Failure9. Evolutionary Design
![Page 10: Eat Your Microservices Elephant One Bite at a Time](https://reader031.vdocument.in/reader031/viewer/2022030304/587a0ae51a28ab01268b69dd/html5/thumbnails/10.jpg)
© 2015 Akana., Inc All Rights Reserved. Powering the API Economy
Additional Guidance• Two-pizza teams • Microservices are highly focused on providing one capability - micro
means singly focused, not size• Microservices have their own lifecycle• Lightweight communication protocols• Right tool for the job• Microservices should have their own datastore separate from other
microservices• Design for failure• Microservice owners responsible for full lifecycle (incl deploy and
operations)
![Page 11: Eat Your Microservices Elephant One Bite at a Time](https://reader031.vdocument.in/reader031/viewer/2022030304/587a0ae51a28ab01268b69dd/html5/thumbnails/11.jpg)
© 2015 Akana., Inc All Rights Reserved. Powering the API Economy
Why are Microservices so popular?
• Slow• Unscalable• Hard to manage
• Faster• Scalable• Easier to manage
![Page 12: Eat Your Microservices Elephant One Bite at a Time](https://reader031.vdocument.in/reader031/viewer/2022030304/587a0ae51a28ab01268b69dd/html5/thumbnails/12.jpg)
© 2015 Akana., Inc All Rights Reserved. Powering the API Economy
How hard is it to adopt Microservices?• Requires 4 things:
– Maturity of ops (need DevOps, Containerization)– Willing to re-architect entire app (maybe)– Willing to invest in the App – must be strategic– App must need Internet scale
![Page 13: Eat Your Microservices Elephant One Bite at a Time](https://reader031.vdocument.in/reader031/viewer/2022030304/587a0ae51a28ab01268b69dd/html5/thumbnails/13.jpg)
© 2015 Akana., Inc All Rights Reserved. Powering the API Economy
Incremental Adoption
![Page 14: Eat Your Microservices Elephant One Bite at a Time](https://reader031.vdocument.in/reader031/viewer/2022030304/587a0ae51a28ab01268b69dd/html5/thumbnails/14.jpg)
© 2015 Akana., Inc All Rights Reserved. Powering the API Economy
Parallel Invocation
![Page 15: Eat Your Microservices Elephant One Bite at a Time](https://reader031.vdocument.in/reader031/viewer/2022030304/587a0ae51a28ab01268b69dd/html5/thumbnails/15.jpg)
© 2015 Akana., Inc All Rights Reserved. Powering the API Economy
What are SOA, APIs and Microservices used for• SOA – is about reuse
– Building services that support multiple different application• APIs – are about supporting web and mobile applications – its about
integration– Geared towards easier and better consumption of services
• Microservices – are about agility and scale– Services enabling scalability and rapid feature cadence for a specific
application
![Page 16: Eat Your Microservices Elephant One Bite at a Time](https://reader031.vdocument.in/reader031/viewer/2022030304/587a0ae51a28ab01268b69dd/html5/thumbnails/16.jpg)
© 2015 Akana., Inc All Rights Reserved. Powering the API Economy
Considerations• Impacts to Design• Impacts to Development• Impacts to Testing
![Page 17: Eat Your Microservices Elephant One Bite at a Time](https://reader031.vdocument.in/reader031/viewer/2022030304/587a0ae51a28ab01268b69dd/html5/thumbnails/17.jpg)
© 2015 Akana., Inc All Rights Reserved. Powering the API Economy
Design• Traditional design oversight is out the window - everyone will use the best
tools available to create the microservice - Govern at the interface• Design request for other interfaces - design-time review of available
interfaces• Design for failure - services should provide health status• Design for robustness - services can self-proxy• Adopt convention - interface must provide for health/resiliency information• Distributed data design - domain-driven design patterns
![Page 18: Eat Your Microservices Elephant One Bite at a Time](https://reader031.vdocument.in/reader031/viewer/2022030304/587a0ae51a28ab01268b69dd/html5/thumbnails/18.jpg)
© 2015 Akana., Inc All Rights Reserved. Powering the API Economy
Development• Development team must know about other available interfaces, etc. -
tooling• Development team must know what libraries, strategies, patterns will
provide for resiliency, health, bulkheads, alternatives• Development team will get to know a lot more about the SDLC before them
and after - full lifecycle responsibility• Development team - agile here with QA intimately involved• Distributed data management requires eventual consistency
accommodation
![Page 19: Eat Your Microservices Elephant One Bite at a Time](https://reader031.vdocument.in/reader031/viewer/2022030304/587a0ae51a28ab01268b69dd/html5/thumbnails/19.jpg)
© 2015 Akana., Inc All Rights Reserved. Powering the API Economy
Testing• Testing at the unit level still exists -
development team’s responsibility• Testing at the integration level still exists -
development team’s responsibility• Testing tools will have to account for new
paradigms for microservices - registry, health dashboard - and build in these scenarios
• Testing inside the service - Delivery as testing
• martinfowler.com/articles/microservice-testing/
![Page 20: Eat Your Microservices Elephant One Bite at a Time](https://reader031.vdocument.in/reader031/viewer/2022030304/587a0ae51a28ab01268b69dd/html5/thumbnails/20.jpg)
© 2015 Akana., Inc All Rights Reserved. Powering the API Economy
How to get there from here• Greenfield development is great, go do it!• Transitioning to microservices isn’t as easy
– Breaking up a monolith requires discipline– Hardest part will probably be separating the data – moving joins to the services
layer and out of the DB– Geographic distribution is still not easy – sharding at the application layer
![Page 21: Eat Your Microservices Elephant One Bite at a Time](https://reader031.vdocument.in/reader031/viewer/2022030304/587a0ae51a28ab01268b69dd/html5/thumbnails/21.jpg)
© 2015 Akana., Inc All Rights Reserved. Powering the API Economy
The Akana Platform in Transition - Original
![Page 22: Eat Your Microservices Elephant One Bite at a Time](https://reader031.vdocument.in/reader031/viewer/2022030304/587a0ae51a28ab01268b69dd/html5/thumbnails/22.jpg)
© 2015 Akana., Inc All Rights Reserved. Powering the API Economy
The Akana Platform in Transition – Phase 1
![Page 23: Eat Your Microservices Elephant One Bite at a Time](https://reader031.vdocument.in/reader031/viewer/2022030304/587a0ae51a28ab01268b69dd/html5/thumbnails/23.jpg)
© 2015 Akana., Inc All Rights Reserved. Powering the API Economy
The Akana Platform in Transition – Phase 3
![Page 24: Eat Your Microservices Elephant One Bite at a Time](https://reader031.vdocument.in/reader031/viewer/2022030304/587a0ae51a28ab01268b69dd/html5/thumbnails/24.jpg)
© 2015 Akana., Inc All Rights Reserved. Powering the API Economy
The Akana Platform in Transition - Final
![Page 25: Eat Your Microservices Elephant One Bite at a Time](https://reader031.vdocument.in/reader031/viewer/2022030304/587a0ae51a28ab01268b69dd/html5/thumbnails/25.jpg)
© 2015 Akana., Inc All Rights Reserved. Powering the API Economy
Questionswww.akana.com