SlideShare a Scribd company logo
Building a microservice ecosystem
Daniel Bryant
@danielbryantuk
OpencRedo
Today
• What is a ‘microservice ecosystem’?
• Local dev of services becomes challenging
• Think about your build pipeline(s)
• Testing requires a paradigm shift
• Push to production as early as possible
24/11/2016 @danielbryantuk
@danielbryantuk
• Chief Scientist at OpenCredo, CTO at SpectoLabs
ü Transforming organisations through technology and teams
ü Agile, Lean, Architecture, CI/CD, DevOps
ü Microservices, cloud, Containers, Java, Go, Docker, Kubernetes
• London Java Community Associate
• Adopt OpenJDK and JSR
• InfoQ Editor, DZone MVB, VOXXED, O'Reilly
24/11/2016 @danielbryantuk
My Biggest Claim to Fame in Microservices?
24/11/2016 @danielbryantuk
Seriously Though...…
24/11/2016 @danielbryantuk
skillsmatter.com/skillscasts/7004-our-journey-to-world-gifting-
domination-how-notonthehighstreet-com-embraced-docker
So, What is a microservice?
“Loosely coupled service oriented architecture
with bounded contexts”
Adrian Cockcroft
“Applications that fit in your head”
James Lewis
24/11/2016 @danielbryantuk
Why? The move towards Cloud-native
• Hypothesis-driven business (and development)
• Microservice architecture (and 'Micro' teams)
• Devops mindset/culture (shared, learning/feedback & Mechanical sympathy)
• Continuous delivery
• Automated, self-service platform
Hat tip @caseywest
24/11/2016 @danielbryantuk
Exploring the Ecosystem
24/11/2016 @danielbryantuk
Adrian Cockcroft’s Thoughts
24/11/2016 @danielbryantuk
www.slideshare.net/adriancockcroft/microxchg-microservices
Alexis Richardson’s Thoughts
24/11/2016 @danielbryantuk
gotocon.com/goto-london-2015/#!#schedulePopupExtras-7011
wikibon.com/wp-content/uploads/container_implementations.png
Technology Choices
24/11/2016 @danielbryantuk
24/11/2016
What do I mean by ‘ecosystem’?
• Build
– Local development, pipelines and integration
• Test
– From local integration to End-to-end
• Deploy
• Operate
• Observe
– Monitoring/logging/alerting
24/11/2016 @danielbryantuk
Don’t forget about (RE)ArchitecturE Complexity
24/11/2016 @danielbryantuk
24/11/2016 @danielbryantuk
www.infoq.com/news/2015/04/raffi-krikorian-rearchitecting
What do I mean by ‘ecosystem’?
• Build
– Local development, pipelines and integration
• Test
– From local integration to End-to-end
• Deploy
• Operate
• Observe
– Monitoring/logging/alerting
24/11/2016 @danielbryantuk
Build
24/11/2016 @danielbryantuk
Developing Locally: The Basics
• GitHub’s Boxen (Puppet)
• Pivotal’s Sprout (Chef)
• Mac-dev-playbook (Ansible)
• Hashicorp Vagrant
• Docker Compose (Docker machine/native)
24/11/2016 @danielbryantuk
Developing Locally
• The naive approach
– Replication of env per service
– …and dependencies and data stores and...
– Soon gets crazy
• Local profiles + mocking/stubbing
– Spring profiles + Mockito etc
24/11/2016 @danielbryantuk
Developing Locally
• Service virtualisation
– Hoverfly, Mountebank, Wiremock (Saboteur)
• ‘Production-in-a-box’ (IFTTT)
– Docker Compose, Vagrant, cf_nise_installer
• Environment leasing
– Create your own env (e.g. Hailo)
24/11/2016 @danielbryantuk
Developing Locally
www.opencredo.com/2015/09/20/working-locally-with-microservices/
24/11/2016 @danielbryantuk
Create a Pipeline
24/11/2016 @danielbryantuk
Key lesson learned (the Hard Way)
• Push through to production as early as possible!
• Detect and fix issues
– Technology
– Process
– People
24/11/2016 @danielbryantuk
Test
24/11/2016 @danielbryantuk
Always Remember...
24/11/2016 @danielbryantuk
blog.bbv.ch/2012/06/13/acceptance-test-driven-development/
Microservice Testing Basics
• Toby Clemson’s article
martinfowler.com/articles/microservice-testing
24/11/2016 @danielbryantuk
Microservice Testing Basics
• My article
https://www.specto.io/blog/recipe-for-designing-building-
testing-microservices.html
24/11/2016 @danielbryantuk
(multiple) Pipelines
• Big-bang release
– Beware of rubber stamping (distributed monolith)
– ‘semver’ if you must (semver.org) e.g. 1.2.1
• Gated release
– Critical path testing in Stage
• Single service Continuous delivery
– Consumer-based contracts
– Backwards compatibility
24/11/2016 @danielbryantuk
Service-level Integration Testing
• Contracts
– Pact-JVM github.com/DiUS/pact-jvm
– PACT broker
github.com/bethesque/pact_broker
– Examples:
github.com/mstine/microservices-pact
24/11/2016 @danielbryantuk
My Opinions
• BDD critical paths throughout application
– Including API journey
• Contract tests (failure is a conversation)
• BDD services API (e.g. Serenity BDD)
• Component test and unit test (as normal)
– Maven surefire/failsafe
24/11/2016 @danielbryantuk
Final Words on Testing
• Don’t forget the ‘ilities”
• Security / reliability
– ZAP (from the OWASP team)
– github.com/continuumsecurity/bdd-security
• Performance / scalability
– Jmeter (Jenkins Performance plugin)
– Gatling
– flood.io
24/11/2016 @danielbryantuk
Deploy
24/11/2016 @danielbryantuk
Separate Deploy and Release
• Feature flags
– Difficult at scale (and distribution)
– Enable at ingress
• Incremental (phased) rollout
• Canary vs blue/green
• Avoid datastore migrations (if possible)
24/11/2016 @danielbryantuk
Centralise Configuration
• Consul & consul-template
• Etcd/ZK & confd
• Netflix Archaius
• Spring Cloud config
• Watch for application rollback!
24/11/2016 @danielbryantuk
Operate
24/11/2016 @danielbryantuk
Building Blocks
• HashiCorp Terraform
– VMWare? cloud-init and vcloud-tools
– “Boot my secure government cloud”
• “CAPS”
– Chef, Ansible, Puppet, SaltStack
– Automated sysadmin
• Docker / Ami / RPM / JAR
– Machine vs Os/lang artifact
• Standardise on an OS
– Amazon Linux vs mainstream distros
24/11/2016 @danielbryantuk
DevOps and Programmable Infrastructure
• Devops involves programming…
• Introduce SOLID principles
• Good CI/CD principles
– Gitflow etc
– Testing
24/11/2016 @danielbryantuk
Service Discovery
• External
– HAProxy / nginx / ELB etc
• Client-side
– Netflix Ribbon (with Prana)
– ‘Baker Street’ (extending SmartStack)
– srv-router
• Kubernetes and CF are good to go
24/11/2016 @danielbryantuk
External
24/11/2016 @danielbryantuk
Client-side
24/11/2016 @danielbryantuk
Observe
24/11/2016 @danielbryantuk
When bad things happen, people are always involved
24/11/2016 @danielbryantuk	|	@oakinger
Monitoring and People
24/11/2016 @danielbryantuk
www.infoq.com/news/2015/06/too-big-to-fail
Start with the Basics
• Health checks
– Coda Hale (DropWizard) Metrics
– Spring Boot actuator
• KPIs for apps (and business)
– Assertions / invariants
– Throughput
– Queue length
24/11/2016 @danielbryantuk
Logging
• What every engineer should know
• 10 Tips for Proper Application Logging
• ElasticSearch-Logstash-Kibana (ELK)
– Buffer/proxy log sending or…
– Mount directory into container
24/11/2016 @danielbryantuk
Monitoring
• Push
– Spring Boot actuator e.g. InfluxDbExporter
• Pull
– E.g. Telegraf (shout to Tareq Abedrabbo)
• InfluxDB vs prometheus vs graphite vs
opentsdb
• Information radiators
– Aggregate vs individual
24/11/2016 @danielbryantuk
Aggregation: Sick Cattle, Not Sick Pets
Opentracing & OpenZipkin
24/11/2016 @danielbryantuk
Problems?
• Rob Ewaschuk’s “Philosophy on Alerting”
• Brendan Gregg’s USE method
– “check utilization, saturation, and errors.”
• “DevOps Troubleshooting”
– Kyle Rankin
24/11/2016 @danielbryantuk
Let’s wrap this up...
24/11/2016 @danielbryantuk
Summary
• development of 3+ services is challenging
• Think about your build pipeline(s)
• Testing requires a paradigm shift
• Operations requires much more automation
• Push through to prod as early as possible
24/11/2016 @danielbryantuk
Bedtime reading
24/11/2016 @danielbryantuk
THANKS...
@danielbryantuk
daniel.bryant@opencredo.com
http://muservicesweekly.com/
(Credit to Tareq Abedrabbo for inspiration/guidance)
24/11/2016 @danielbryantuk
Logging vs monitoring
• Logging
– Primarily used post-incident
– Machine readable
– Hard to do right
– Noise/signal
• Monitoring
– Useful in Real time during incident
– Trend analysis
– Easier to do
24/11/2016 @danielbryantuk

More Related Content

PDF
GOTO LONDON 2016: Concursus Event sourcing Evolved (Updated)
PDF
The seven deadly sins of microservices
PDF
The seven more deadly sins of microservices final
PDF
muCon 2016: "Seven (More) Deadly Sins of Microservices"
PDF
Reactive Principles and Microservices
PDF
Haufe #msaday: "Building a Microservice Ecosystem"
PPTX
LJCConf 2013 "Chuck Norris Doesn't Need DevOps"
PDF
Microservices - Scaling Development and Service
GOTO LONDON 2016: Concursus Event sourcing Evolved (Updated)
The seven deadly sins of microservices
The seven more deadly sins of microservices final
muCon 2016: "Seven (More) Deadly Sins of Microservices"
Reactive Principles and Microservices
Haufe #msaday: "Building a Microservice Ecosystem"
LJCConf 2013 "Chuck Norris Doesn't Need DevOps"
Microservices - Scaling Development and Service

What's hot (12)

PPTX
LJC: "Chuck Norris Doesn't Do DevOps...but Java developers might benefit"
PPTX
JavaOne 2014: Cloud Developer's DHARMA: Redefining 'done' for Cloud applications
PDF
Evolve 2017 - Vegas - Devops, Docker and Security
PDF
ServerlessConf: Serverless for the Enterprise - Rafal Gancarz
PPTX
ThingMonk 2016 - Concursus Event sourcing for the IOT By Tareq Abedrabbo & Do...
PPTX
Get Your **IT Together: Log Retention, Clean-Up, & Compliance
PPT
Heroku for team collaboration
PDF
The Serverless Paradigm, OpenWhisk and FIWARE
PPTX
Liberty Summit - Symantec Open Community
PDF
Should i break it?
PDF
Going Serverless with OpenWhisk
PDF
Microservices, DevOps, and Containers with OpenShift and Fabric8
LJC: "Chuck Norris Doesn't Do DevOps...but Java developers might benefit"
JavaOne 2014: Cloud Developer's DHARMA: Redefining 'done' for Cloud applications
Evolve 2017 - Vegas - Devops, Docker and Security
ServerlessConf: Serverless for the Enterprise - Rafal Gancarz
ThingMonk 2016 - Concursus Event sourcing for the IOT By Tareq Abedrabbo & Do...
Get Your **IT Together: Log Retention, Clean-Up, & Compliance
Heroku for team collaboration
The Serverless Paradigm, OpenWhisk and FIWARE
Liberty Summit - Symantec Open Community
Should i break it?
Going Serverless with OpenWhisk
Microservices, DevOps, and Containers with OpenShift and Fabric8
Ad

Viewers also liked (20)

PDF
A Visual Introduction to Event Sourcing and CQRS by Lorenzo Nicora
PDF
Haufe #msaday - Seven More Deadly Sins of Microservices by Daniel Bryant
PDF
Voxxed Bristol 2017 - From C to Q, one event at a time: Event Sourcing illust...
PDF
Reactive Microservices By Lorenzo Nicora
PPTX
O'Reilly 2016: "Continuous Delivery with Containers: The Trials and Tribulati...
PDF
Haufe #msaday - The Actor model: an alternative approach to concurrency By Lo...
PDF
QCON London 2017 - Monitoring Serverless Architectures by Rafal Gancarz
PDF
London Hashicorp Meetup #8 - Testing Programmable Infrastructure By Matt Long
PDF
Evolving Project Management: from the sin to the virtue by Antonio Cobo
PDF
High Load Strategy 2016 - Project Management: from Stone Age to DevOps
PDF
muCon 2016: Authentication in Microservice Systems By David Borsos
PDF
Microservices Manchester: Microservices and Macro-Economics - A Shorty Histor...
PDF
Vault: Beyond secret storage - Using Vault to harden your infrastructure
PDF
Microservices Manchester: Security, Microservces and Vault by Nicki Watt
PPTX
Microservices Manchester: Authentication in Microservice Systems by David Borsos
PDF
Spring Boot Microservices vs Akka Actor Cluster
PDF
Netflix oss past-present-future
PDF
Arquitecturas de microservicios - @cibbva
PDF
Hashicorp Tools For The Windows Ecosystem
PDF
Api gateway migration
A Visual Introduction to Event Sourcing and CQRS by Lorenzo Nicora
Haufe #msaday - Seven More Deadly Sins of Microservices by Daniel Bryant
Voxxed Bristol 2017 - From C to Q, one event at a time: Event Sourcing illust...
Reactive Microservices By Lorenzo Nicora
O'Reilly 2016: "Continuous Delivery with Containers: The Trials and Tribulati...
Haufe #msaday - The Actor model: an alternative approach to concurrency By Lo...
QCON London 2017 - Monitoring Serverless Architectures by Rafal Gancarz
London Hashicorp Meetup #8 - Testing Programmable Infrastructure By Matt Long
Evolving Project Management: from the sin to the virtue by Antonio Cobo
High Load Strategy 2016 - Project Management: from Stone Age to DevOps
muCon 2016: Authentication in Microservice Systems By David Borsos
Microservices Manchester: Microservices and Macro-Economics - A Shorty Histor...
Vault: Beyond secret storage - Using Vault to harden your infrastructure
Microservices Manchester: Security, Microservces and Vault by Nicki Watt
Microservices Manchester: Authentication in Microservice Systems by David Borsos
Spring Boot Microservices vs Akka Actor Cluster
Netflix oss past-present-future
Arquitecturas de microservicios - @cibbva
Hashicorp Tools For The Windows Ecosystem
Api gateway migration
Ad

Similar to Haufe #msaday - Building a Microservice Ecosystem by Daniel Bryant (20)

PDF
vJUG24 2016 "Seven (More) Deadly Sins of Microservice"
PDF
Micro Manchester Meetup: "The Seven (More) Deadly Sins of Microservices"
PPTX
O'Reilly/Nginx 2016: "Continuous Delivery with Containers: The Trials and Tri...
PPTX
muCon 2014 "Building Java Microservices for the Cloud"
PPTX
OReilly SACON 2016 "A Practical Guide for Continuous Delivery with Containers"
PPTX
LJC Mashup "Building Java Microservices for the Cloud && Chuck Norris Doesn't...
PDF
Devoxx US 2017 "The Seven (More) Deadly Sins of Microservices"
PPTX
J1 2015 "Building a Microservice Ecosystem: Some Assembly Still Required"
PDF
SwisscomSoftwareDay 2016 "The Trials and Tribulations of Making Software Small"
PPTX
O'Reilly SACON "Continuous Delivery Patterns for Contemporary Architecture"
PPTX
TTN 2015 "Defining DevOps: Concepts, Technology and Automation. Oh yeah, and ...
PDF
ZTLive 2016 "Introduction to Microservices"
PDF
OSCON EU 2016 "Seven (More) Deadly Sins of Microservices"
PDF
Microservices Manchester: Welcome To Microservices Manchester By Daniel Bryant
PDF
MicroManchester 2016 "A Brief Guide to Microservices"
PDF
JAXDevOps 2017 "The Seven (More) Deadly Sins of Microservices
PDF
AllDayDevOps: "Microservices: The People and Organisational Impact"
PDF
GOTO Chicago/CraftConf 2017 "The Seven (More) Deadly Sins of Microservices"
PDF
ACCU16 "Let's Not Repeat the Mistakes of SOA: 'Micro' Services, Macro Organis...
PPTX
JAX DevOps 2018 "Continuous Delivery Patterns for Modern Architectures"
vJUG24 2016 "Seven (More) Deadly Sins of Microservice"
Micro Manchester Meetup: "The Seven (More) Deadly Sins of Microservices"
O'Reilly/Nginx 2016: "Continuous Delivery with Containers: The Trials and Tri...
muCon 2014 "Building Java Microservices for the Cloud"
OReilly SACON 2016 "A Practical Guide for Continuous Delivery with Containers"
LJC Mashup "Building Java Microservices for the Cloud && Chuck Norris Doesn't...
Devoxx US 2017 "The Seven (More) Deadly Sins of Microservices"
J1 2015 "Building a Microservice Ecosystem: Some Assembly Still Required"
SwisscomSoftwareDay 2016 "The Trials and Tribulations of Making Software Small"
O'Reilly SACON "Continuous Delivery Patterns for Contemporary Architecture"
TTN 2015 "Defining DevOps: Concepts, Technology and Automation. Oh yeah, and ...
ZTLive 2016 "Introduction to Microservices"
OSCON EU 2016 "Seven (More) Deadly Sins of Microservices"
Microservices Manchester: Welcome To Microservices Manchester By Daniel Bryant
MicroManchester 2016 "A Brief Guide to Microservices"
JAXDevOps 2017 "The Seven (More) Deadly Sins of Microservices
AllDayDevOps: "Microservices: The People and Organisational Impact"
GOTO Chicago/CraftConf 2017 "The Seven (More) Deadly Sins of Microservices"
ACCU16 "Let's Not Repeat the Mistakes of SOA: 'Micro' Services, Macro Organis...
JAX DevOps 2018 "Continuous Delivery Patterns for Modern Architectures"

More from OpenCredo (12)

PDF
Webinar - Design Thinking for Platform Engineering
PDF
MuCon 2019: Exploring Your Microservices Architecture Through Network Science...
PDF
Goto Chicago; Journeys To Cloud Native Architecture: Sun, Sea And Emergencies...
PPTX
Mucon 2018: Heuristics for Identifying Microservice Boundaries By Erich Eichi...
PDF
Journeys To Cloud Native Architecture: Sun, Sea And Emergencies - Nicki Watt
PDF
Machine Learning Game Changer for IT - Maartens Lourens
PDF
Kafka Summit 2018: A Journey Building Kafka Connectors - Pegerto Fernandez
PDF
MuCon 2017: A not So(A) Trivial Question by Tareq Abedrabbo
PDF
DevOpsCon Berlin 2017: Project Management from Stone Age to DevOps By Antoni...
PDF
Hashidays London 2017 - Evolving your Infrastructure with Terraform By Nicki ...
PDF
Succeeding with DevOps Transformation - Rafal Gancarz
PDF
Progscon 2017: Serverless Architectures - Rafal Gancarz
Webinar - Design Thinking for Platform Engineering
MuCon 2019: Exploring Your Microservices Architecture Through Network Science...
Goto Chicago; Journeys To Cloud Native Architecture: Sun, Sea And Emergencies...
Mucon 2018: Heuristics for Identifying Microservice Boundaries By Erich Eichi...
Journeys To Cloud Native Architecture: Sun, Sea And Emergencies - Nicki Watt
Machine Learning Game Changer for IT - Maartens Lourens
Kafka Summit 2018: A Journey Building Kafka Connectors - Pegerto Fernandez
MuCon 2017: A not So(A) Trivial Question by Tareq Abedrabbo
DevOpsCon Berlin 2017: Project Management from Stone Age to DevOps By Antoni...
Hashidays London 2017 - Evolving your Infrastructure with Terraform By Nicki ...
Succeeding with DevOps Transformation - Rafal Gancarz
Progscon 2017: Serverless Architectures - Rafal Gancarz

Recently uploaded (20)

PPTX
VMware vSphere Foundation How to Sell Presentation-Ver1.4-2-14-2024.pptx
PDF
Modernizing your data center with Dell and AMD
PDF
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
PPTX
Effective Security Operations Center (SOC) A Modern, Strategic, and Threat-In...
PDF
Dropbox Q2 2025 Financial Results & Investor Presentation
PDF
Empathic Computing: Creating Shared Understanding
PDF
Shreyas Phanse Resume: Experienced Backend Engineer | Java • Spring Boot • Ka...
PPTX
Cloud computing and distributed systems.
PDF
Blue Purple Modern Animated Computer Science Presentation.pdf.pdf
PPTX
A Presentation on Artificial Intelligence
PDF
Architecting across the Boundaries of two Complex Domains - Healthcare & Tech...
PDF
Machine learning based COVID-19 study performance prediction
PDF
KodekX | Application Modernization Development
PDF
Encapsulation theory and applications.pdf
PPT
“AI and Expert System Decision Support & Business Intelligence Systems”
PDF
NewMind AI Monthly Chronicles - July 2025
PDF
NewMind AI Weekly Chronicles - August'25 Week I
PDF
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows
PPT
Teaching material agriculture food technology
PDF
Network Security Unit 5.pdf for BCA BBA.
VMware vSphere Foundation How to Sell Presentation-Ver1.4-2-14-2024.pptx
Modernizing your data center with Dell and AMD
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
Effective Security Operations Center (SOC) A Modern, Strategic, and Threat-In...
Dropbox Q2 2025 Financial Results & Investor Presentation
Empathic Computing: Creating Shared Understanding
Shreyas Phanse Resume: Experienced Backend Engineer | Java • Spring Boot • Ka...
Cloud computing and distributed systems.
Blue Purple Modern Animated Computer Science Presentation.pdf.pdf
A Presentation on Artificial Intelligence
Architecting across the Boundaries of two Complex Domains - Healthcare & Tech...
Machine learning based COVID-19 study performance prediction
KodekX | Application Modernization Development
Encapsulation theory and applications.pdf
“AI and Expert System Decision Support & Business Intelligence Systems”
NewMind AI Monthly Chronicles - July 2025
NewMind AI Weekly Chronicles - August'25 Week I
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows
Teaching material agriculture food technology
Network Security Unit 5.pdf for BCA BBA.

Haufe #msaday - Building a Microservice Ecosystem by Daniel Bryant