Welcome!
To the first Vancouver
Microservices Meetup
June 15, 2017
Brought to you by:
Agenda
 Welcome and Introductions
 The Microservices Way, Matt McLarty, VP
of the API Academy at CA
Technologies
 Microservices at Hootsuite, Mike Sample,
Director of Technology, Hootsuite
 Open Discussion
June 15, 2017
© 2017 CA. All rights reserved.
The Microservices Way
Speed and Safety at Scale
Matt McLarty
Vice President, The API Academy, CA Technologies
matthew.mclarty@ca.com
@mattmclartybc
CA Technologies in Vancouver
2002-2013 2013-Now
5 © 2017 CA. ALL RIGHTS RESERVED.
The API Academy
Strategy, architecture and design
guidance on APIs and microservices
Tailored education and consulting
from known experts
Industry leadership through
publications and presentations
6 © 2017 CA. ALL RIGHTS RESERVED.
What we’re going to cover…
WHAT ARE MICROSERVICES?
WHERE DID THEY COME FROM?
WHY DO THEY MATTER?
WHAT ARE THE HARD PARTS?
7 © 2017 CA. ALL RIGHTS RESERVED.
What are Microservices?
 Unbundled services
 Bounded contexts
 Exposed through APIs
 Minimal dependencies
 Assembled to form applications
 Distinguished from monolithic
applications
Image from http://martinfowler.com/articles/microservices.html
8 © 2017 CA. ALL RIGHTS RESERVED.
Microservice Definitions
A microservice is an independently
deployable component of bounded
scope that supports interoperability
through message-based communication.
Microservice architecture is a style of
engineering highly-automated, evolvable
software systems made up of capability-
aligned microservices.
9 © 2017 CA. ALL RIGHTS RESERVED.
Microservices = Service-Oriented Architecture?
“For us service orientation means
encapsulating the data with the business logic
that operates on the data, with the only access
through a published service interface.”
- Werner Vogels, AWS CTO
https://queue.acm.org/detail.cfm?id=1142065
“Microservices is SOA with emphasis on small
ephemeral components.”
- Adrian Cockroft, Battery Ventures, ex-Netflix
https://twitter.com/adrianco/status/542850261782237184
10 © 2017 CA. ALL RIGHTS RESERVED.
Microservice principles
Decompose into discrete services to enable continuous delivery
Reduce dependencies to facilitate frequent change
Remove bottlenecks to speed up development
Developed and supported by small, empowered, business-aligned teams
Break the system down into understandable and manageable parts
Reduce the amount of unchanged code that gets deployed
11 © 2017 CA. ALL RIGHTS RESERVED.
These are Agile principles!
Decompose into discrete services to enable continuous delivery
Reduce dependencies to facilitate frequent change
Remove bottlenecks to speed up development
Developed and supported by small, empowered, business-aligned teams
Break the system down into understandable and manageable parts
Reduce the amount of unchanged code that gets deployed
12 © 2017 CA. ALL RIGHTS RESERVED.
The Agile Progression
Agile Software Development
Continuous Delivery
DevOps
Microservice Architecture
13 © 2017 CA. ALL RIGHTS RESERVED.
Business Value Stories
“We can scale our operation independently, maintain unparalleled system availability, and
introduce new services quickly without the need for massive reconfiguration.”
•Werner Vogels, Amazon (2006) https://queue.acm.org/detail.cfm?id=1142065
“…the next generation [architecture] that we are building will give Netflix a strong foundation to
meet the needs of our massive and growing scale, enabling us to delight our global audience.”
•Netflix (2015) http://techblog.netflix.com/2015/01/netflixs-viewing-data-how-we-know-where.html
“Lessens dependencies between teams - resulting in faster code to production.”
•Adrian Trenaman, Gilt (2015) http://www.infoq.com/news/2015/04/scaling-microservices-gilt
“With the new architecture framework, we were able to reduce our lead time for new features to
something that…was much more acceptable for a company trying to play in the highly competitive
music industry.”
•Phil Calçado, SoundCloud (2015) http://philcalcado.com/2015/09/08/how_we_ended_up_with_microservices.html
14 © 2017 CA. ALL RIGHTS RESERVED.
The Microservices Way
Speed and safety at scale
15 © 2017 CA. ALL RIGHTS RESERVED.
The Microservices Way
Speed and safety at scale
Structuring a complex software system that allows
16 © 2017 CA. ALL RIGHTS RESERVED.
Software Complexity
17 © 2017 CA. ALL RIGHTS RESERVED.
Essential vs. Accidental Complexity
Essential Complexity
• The complexity of the software’s functional scope and the
problems it solves (e.g. correlating and analyzing large amounts
of data in real time)
Accidental Complexity
• The complexity of the software’s implementation details (e.g.
the languages, processes and messages used to do the work)
18 © 2017 CA. ALL RIGHTS RESERVED.
Software Complexity
“Many of the classical problems of
developing software products derived
from this essential complexity and its
nonlinear increased with size.”
- Fred Brooks, “No Silver Bullet—Essence and
Accident in Software Engineering”
http://www.cs.nott.ac.uk/~pszcah/G51ISS/Documents/NoSilverBullet.html
19 © 2017 CA. ALL RIGHTS RESERVED.
Complexity in Microservices
Essential Complexity in Microservices
• In a microservice architecture, the topology of the
implemented system closely resembles the model of the
system’s “essence”
Accidental Complexity in Microservices
• In a microservice architecture, accidental complexity can be
minimized through automation and distribution
20 © 2017 CA. ALL RIGHTS RESERVED.
Dealing with Essential Complexity in Microservices
 Effectively modeling essential complexity
reduces the need for coordination
 Eric Evans’ Domain-Driven Design provides a
framework for defining and modeling the
essential capabilities of complex software
systems
Image credit: http://martinfowler.com/bliki/BoundedContext.html
21 © 2017 CA. ALL RIGHTS RESERVED.
Dealing with Accidental Complexity in Microservices
From Ronnie Mitra’s
Presentation, “Designing a
Microservices Architecture”, at
CA World 2015
http://www.apiacademy.co/reso
urces/designing-a-microservices-
architecture/
22 © 2017 CA. ALL RIGHTS RESERVED.
Getting started with microservices
Identify your goals
• Delivery speed? Operational agility?
Define your scope
• Division? Group? Application? Projected change frequency?
Determine your baseline and set targets
• Define metrics, measure current state, set iteration frequency
Establish pre-requisite capabilities
• Methodology, culture, organization, foundation
Use APIs as building blocks and stepping stones
• To sketch the system, map communication, isolate domains
23 © 2017 CA. ALL RIGHTS RESERVED.
APIs vs. Microservices
API
 An application interface exposed
on a network
 Can use many styles (RPC, CRUD,
REST), protocols (HTTP, Kafka,
gRPC) and data formats (JSON,
XML, protobuf)
 Can be implemented in many
ways (standalone microservice,
monolithic application, API
gateway, ESB)
Microservice
 Independently deployable
application component
 Often self-contained (interface,
logic, data)
 Exposes functionality to other
services and external clients via
APIs
24 © 2017 CA. ALL RIGHTS RESERVED.
APIs for Microservices
APIs describe the functional capabilities of the system
• They allow architects to view and model the system without diving into the weeds
• They facilitate conversation between business and technology people
APIs offer a transition path to microservices
• Monolithic application services can be offered through APIs as a stepping stone
• This insulates service consumers from changes on the back end
APIs provide a normalized access point for system functions
• They provide interoperability between components
• Single point in the system to address security, composition, monitoring, and SLAs
25 © 2017 CA. ALL RIGHTS RESERVED.
Microservices: The Hard Parts
System
Monitoring and
Management
Domain
Decomposition
Security and
Policy
Enforcement
All the other
“system stuff”
26 © 2017 CA. ALL RIGHTS RESERVED.
A Design-Based Approach to Microservice Architecture
• Define the goalsOutcome Design
• Decompose the domainSystem Design
• Design the serviceService Design
• Determine the needed capabilitiesFoundation Design
• Address processes and cultureOrganizational Design
27 © 2017 CA. ALL RIGHTS RESERVED.
In summary…
Microservice architecture emerged from the Agile Progression
Microservices can bring speed and safety at scale
It’s important to distinguish between essential and accidental complexity
APIs are vital building blocks for succeeding with microservices
Organizations should take a broad but iterative approach
28 © 2017 CA. ALL RIGHTS RESERVED.
Questions?
29 © 2017 CA. ALL RIGHTS RESERVED.
For more information…
The API Academy
•http://www.apiacademy.co/
•Mike Amundsen, “Establishing a Foundation for Microservices” - http://amundsen.com/talks/2016-09-api-world/2016-09-apiworld-foundations.pdf
•Ronnie Mitra, “Designing a Microservices Architecture” - http://www.apiacademy.co/resources/designing-a-microservices-architecture/
•Erik Wilde, “Patterns for Robust Extensibility” - http://dret.typepad.com/dretblog/2016/04/robust-extensibility.html
•Matt McLarty, “Designing a System of Microservices” - http://www.apiacademy.co/designing-a-system-of-microservices/
Microservice Architecture from O’Reilly:
•http://transform.ca.com/API-microservice-architecture-oreilly-book.html
Presentations from the API360 Microservices Summit in New York (June 16):
•http://transform.ca.com/API-Microservices-Best-Practices-API360-Summit-Videos.html
Infoworld articles:
•http://www.infoworld.com/article/3075880/application-development/microservice-architecture-is-agile-software-architecture.html
•http://www.infoworld.com/article/3080611/application-development/learning-from-soa-5-lessons-for-the-microservices-era.html
Third Party Resources:
•“A conversation with Werner Vogels” - https://queue.acm.org/detail.cfm?id=1142065
•Phil Calcado, “How we ended up with microservices” - http://philcalcado.com/2015/09/08/how_we_ended_up_with_microservices.html
•Ben Christensen, “Don’t build a distributed monolith” - https://www.youtube.com/watch?v=-czp0Y4Z36Y
•Holger Reinhardt, “The automated monolith” - http://transform.ca.com/API-Microservices-Best-Practices-API360-Summit-Videos.html
•Irakli Nadareishvili, “Microservices: The Rule of Twos” - http://www.freshblurbs.com/blog/2016/10/09/microservicies-rule-of-twos.html
•James Higginbotham, “Applying Domain Driven Design to APIs and Microservices” - http://www.slideshare.net/launchany/applying-domaindriven-design-to-apis-
and-microservices-austin-api-meetup https://www.youtube.com/watch?v=i98rpH4mwIc

Vancouver Microservices Meetup - Kickoff Session

  • 1.
    Welcome! To the firstVancouver Microservices Meetup June 15, 2017 Brought to you by:
  • 2.
    Agenda  Welcome andIntroductions  The Microservices Way, Matt McLarty, VP of the API Academy at CA Technologies  Microservices at Hootsuite, Mike Sample, Director of Technology, Hootsuite  Open Discussion
  • 3.
    June 15, 2017 ©2017 CA. All rights reserved. The Microservices Way Speed and Safety at Scale Matt McLarty Vice President, The API Academy, CA Technologies matthew.mclarty@ca.com @mattmclartybc
  • 4.
    CA Technologies inVancouver 2002-2013 2013-Now
  • 5.
    5 © 2017CA. ALL RIGHTS RESERVED. The API Academy Strategy, architecture and design guidance on APIs and microservices Tailored education and consulting from known experts Industry leadership through publications and presentations
  • 6.
    6 © 2017CA. ALL RIGHTS RESERVED. What we’re going to cover… WHAT ARE MICROSERVICES? WHERE DID THEY COME FROM? WHY DO THEY MATTER? WHAT ARE THE HARD PARTS?
  • 7.
    7 © 2017CA. ALL RIGHTS RESERVED. What are Microservices?  Unbundled services  Bounded contexts  Exposed through APIs  Minimal dependencies  Assembled to form applications  Distinguished from monolithic applications Image from http://martinfowler.com/articles/microservices.html
  • 8.
    8 © 2017CA. ALL RIGHTS RESERVED. Microservice Definitions A microservice is an independently deployable component of bounded scope that supports interoperability through message-based communication. Microservice architecture is a style of engineering highly-automated, evolvable software systems made up of capability- aligned microservices.
  • 9.
    9 © 2017CA. ALL RIGHTS RESERVED. Microservices = Service-Oriented Architecture? “For us service orientation means encapsulating the data with the business logic that operates on the data, with the only access through a published service interface.” - Werner Vogels, AWS CTO https://queue.acm.org/detail.cfm?id=1142065 “Microservices is SOA with emphasis on small ephemeral components.” - Adrian Cockroft, Battery Ventures, ex-Netflix https://twitter.com/adrianco/status/542850261782237184
  • 10.
    10 © 2017CA. ALL RIGHTS RESERVED. Microservice principles Decompose into discrete services to enable continuous delivery Reduce dependencies to facilitate frequent change Remove bottlenecks to speed up development Developed and supported by small, empowered, business-aligned teams Break the system down into understandable and manageable parts Reduce the amount of unchanged code that gets deployed
  • 11.
    11 © 2017CA. ALL RIGHTS RESERVED. These are Agile principles! Decompose into discrete services to enable continuous delivery Reduce dependencies to facilitate frequent change Remove bottlenecks to speed up development Developed and supported by small, empowered, business-aligned teams Break the system down into understandable and manageable parts Reduce the amount of unchanged code that gets deployed
  • 12.
    12 © 2017CA. ALL RIGHTS RESERVED. The Agile Progression Agile Software Development Continuous Delivery DevOps Microservice Architecture
  • 13.
    13 © 2017CA. ALL RIGHTS RESERVED. Business Value Stories “We can scale our operation independently, maintain unparalleled system availability, and introduce new services quickly without the need for massive reconfiguration.” •Werner Vogels, Amazon (2006) https://queue.acm.org/detail.cfm?id=1142065 “…the next generation [architecture] that we are building will give Netflix a strong foundation to meet the needs of our massive and growing scale, enabling us to delight our global audience.” •Netflix (2015) http://techblog.netflix.com/2015/01/netflixs-viewing-data-how-we-know-where.html “Lessens dependencies between teams - resulting in faster code to production.” •Adrian Trenaman, Gilt (2015) http://www.infoq.com/news/2015/04/scaling-microservices-gilt “With the new architecture framework, we were able to reduce our lead time for new features to something that…was much more acceptable for a company trying to play in the highly competitive music industry.” •Phil Calçado, SoundCloud (2015) http://philcalcado.com/2015/09/08/how_we_ended_up_with_microservices.html
  • 14.
    14 © 2017CA. ALL RIGHTS RESERVED. The Microservices Way Speed and safety at scale
  • 15.
    15 © 2017CA. ALL RIGHTS RESERVED. The Microservices Way Speed and safety at scale Structuring a complex software system that allows
  • 16.
    16 © 2017CA. ALL RIGHTS RESERVED. Software Complexity
  • 17.
    17 © 2017CA. ALL RIGHTS RESERVED. Essential vs. Accidental Complexity Essential Complexity • The complexity of the software’s functional scope and the problems it solves (e.g. correlating and analyzing large amounts of data in real time) Accidental Complexity • The complexity of the software’s implementation details (e.g. the languages, processes and messages used to do the work)
  • 18.
    18 © 2017CA. ALL RIGHTS RESERVED. Software Complexity “Many of the classical problems of developing software products derived from this essential complexity and its nonlinear increased with size.” - Fred Brooks, “No Silver Bullet—Essence and Accident in Software Engineering” http://www.cs.nott.ac.uk/~pszcah/G51ISS/Documents/NoSilverBullet.html
  • 19.
    19 © 2017CA. ALL RIGHTS RESERVED. Complexity in Microservices Essential Complexity in Microservices • In a microservice architecture, the topology of the implemented system closely resembles the model of the system’s “essence” Accidental Complexity in Microservices • In a microservice architecture, accidental complexity can be minimized through automation and distribution
  • 20.
    20 © 2017CA. ALL RIGHTS RESERVED. Dealing with Essential Complexity in Microservices  Effectively modeling essential complexity reduces the need for coordination  Eric Evans’ Domain-Driven Design provides a framework for defining and modeling the essential capabilities of complex software systems Image credit: http://martinfowler.com/bliki/BoundedContext.html
  • 21.
    21 © 2017CA. ALL RIGHTS RESERVED. Dealing with Accidental Complexity in Microservices From Ronnie Mitra’s Presentation, “Designing a Microservices Architecture”, at CA World 2015 http://www.apiacademy.co/reso urces/designing-a-microservices- architecture/
  • 22.
    22 © 2017CA. ALL RIGHTS RESERVED. Getting started with microservices Identify your goals • Delivery speed? Operational agility? Define your scope • Division? Group? Application? Projected change frequency? Determine your baseline and set targets • Define metrics, measure current state, set iteration frequency Establish pre-requisite capabilities • Methodology, culture, organization, foundation Use APIs as building blocks and stepping stones • To sketch the system, map communication, isolate domains
  • 23.
    23 © 2017CA. ALL RIGHTS RESERVED. APIs vs. Microservices API  An application interface exposed on a network  Can use many styles (RPC, CRUD, REST), protocols (HTTP, Kafka, gRPC) and data formats (JSON, XML, protobuf)  Can be implemented in many ways (standalone microservice, monolithic application, API gateway, ESB) Microservice  Independently deployable application component  Often self-contained (interface, logic, data)  Exposes functionality to other services and external clients via APIs
  • 24.
    24 © 2017CA. ALL RIGHTS RESERVED. APIs for Microservices APIs describe the functional capabilities of the system • They allow architects to view and model the system without diving into the weeds • They facilitate conversation between business and technology people APIs offer a transition path to microservices • Monolithic application services can be offered through APIs as a stepping stone • This insulates service consumers from changes on the back end APIs provide a normalized access point for system functions • They provide interoperability between components • Single point in the system to address security, composition, monitoring, and SLAs
  • 25.
    25 © 2017CA. ALL RIGHTS RESERVED. Microservices: The Hard Parts System Monitoring and Management Domain Decomposition Security and Policy Enforcement All the other “system stuff”
  • 26.
    26 © 2017CA. ALL RIGHTS RESERVED. A Design-Based Approach to Microservice Architecture • Define the goalsOutcome Design • Decompose the domainSystem Design • Design the serviceService Design • Determine the needed capabilitiesFoundation Design • Address processes and cultureOrganizational Design
  • 27.
    27 © 2017CA. ALL RIGHTS RESERVED. In summary… Microservice architecture emerged from the Agile Progression Microservices can bring speed and safety at scale It’s important to distinguish between essential and accidental complexity APIs are vital building blocks for succeeding with microservices Organizations should take a broad but iterative approach
  • 28.
    28 © 2017CA. ALL RIGHTS RESERVED. Questions?
  • 29.
    29 © 2017CA. ALL RIGHTS RESERVED. For more information… The API Academy •http://www.apiacademy.co/ •Mike Amundsen, “Establishing a Foundation for Microservices” - http://amundsen.com/talks/2016-09-api-world/2016-09-apiworld-foundations.pdf •Ronnie Mitra, “Designing a Microservices Architecture” - http://www.apiacademy.co/resources/designing-a-microservices-architecture/ •Erik Wilde, “Patterns for Robust Extensibility” - http://dret.typepad.com/dretblog/2016/04/robust-extensibility.html •Matt McLarty, “Designing a System of Microservices” - http://www.apiacademy.co/designing-a-system-of-microservices/ Microservice Architecture from O’Reilly: •http://transform.ca.com/API-microservice-architecture-oreilly-book.html Presentations from the API360 Microservices Summit in New York (June 16): •http://transform.ca.com/API-Microservices-Best-Practices-API360-Summit-Videos.html Infoworld articles: •http://www.infoworld.com/article/3075880/application-development/microservice-architecture-is-agile-software-architecture.html •http://www.infoworld.com/article/3080611/application-development/learning-from-soa-5-lessons-for-the-microservices-era.html Third Party Resources: •“A conversation with Werner Vogels” - https://queue.acm.org/detail.cfm?id=1142065 •Phil Calcado, “How we ended up with microservices” - http://philcalcado.com/2015/09/08/how_we_ended_up_with_microservices.html •Ben Christensen, “Don’t build a distributed monolith” - https://www.youtube.com/watch?v=-czp0Y4Z36Y •Holger Reinhardt, “The automated monolith” - http://transform.ca.com/API-Microservices-Best-Practices-API360-Summit-Videos.html •Irakli Nadareishvili, “Microservices: The Rule of Twos” - http://www.freshblurbs.com/blog/2016/10/09/microservicies-rule-of-twos.html •James Higginbotham, “Applying Domain Driven Design to APIs and Microservices” - http://www.slideshare.net/launchany/applying-domaindriven-design-to-apis- and-microservices-austin-api-meetup https://www.youtube.com/watch?v=i98rpH4mwIc