18
Microservices: Lessons Learned Or how I learned to stop worrying and love Continuous Deployment… Tom Wilkie Weaveworks, September 2016

Microservices: Lessons Learned

Embed Size (px)

Citation preview

Page 1: Microservices: Lessons Learned

Microservices: Lessons LearnedOr how I learned to stop worrying and love

Continuous Deployment…

Tom Wilkie Weaveworks, September 2016

Page 2: Microservices: Lessons Learned
Page 3: Microservices: Lessons Learned

https://github.com/weaveworks/scope

Page 4: Microservices: Lessons Learned

http://cloud.weave.works/

Page 5: Microservices: Lessons Learned

DEMO

Page 6: Microservices: Lessons Learned

✓Emergent Microservices Architecture

✓Worse-is-better*

✓Optimise for MTTR

✓DevOps

✓Continuous Delivery

* https://blog.acolyer.org/2016/09/15/the-rise-of-worse-is-better/

Page 7: Microservices: Lessons Learned

Emergent Microservice Architecture

Page 8: Microservices: Lessons Learned

scope-probescope-probe

scope-app

Browser

scope-probe

Host 1 Host 2 Host 3

Scope OSS Architecture

Page 9: Microservices: Lessons Learned

Frontend (Nginx)

WeaverangAccount Service

scope-apps

The Interwebs

/api/app/*/api/user/*

scope-appsscope-apps

App Mapper

scope-app

Frontend (Nginx)

Routed based on credentials/identity

RDS Instance

RDS InstanceAccount Service

Static Content Server

/*

Open SourceClosed SourceAWS Service

Service Architecture ~Sept 2015

Page 10: Microservices: Lessons Learned

Account Service

Frontend (Nginx)

The Interwebs

Weaverang

/api/report

Collection Service

/api/user

RDS Instance

Users Service

Static Content Server

/*

AWS DynamoDB

/api/<app>/api/topology

Query Service Weaverang

/api/<app>/api/control

Control Service

Frontend (Nginx)

AWS SQS

Frontend (Nginx)Authenticating Proxy

Weaverang

/api/<app>/api/pipe

Pipe Service

AWS S3 Consul Cluster

Open SourceClosed SourceAWS Service

NATS Cluster

Service Architecture ~Jun 2016

Page 11: Microservices: Lessons Learned

OSS Scope

}1. Incoming reports

2. Stored in memory

3. Outgoing queries

}1. Incoming reports

2. Stored in S3 / DynamoDB / Memcache

3. Outgoing queries

Weave Cloud

Page 12: Microservices: Lessons Learned

ContinuousDeployment

Page 13: Microservices: Lessons Learned

App is developed & tested locally

Built automatically using CI of your

choice

Container image pushed

automatically

Deployed automatically using

Weave Cloud deploy service...

...to an Environment of your choice

Source control Configuration as code

Page 14: Microservices: Lessons Learned
Page 15: Microservices: Lessons Learned

Take aways

Page 16: Microservices: Lessons Learned

DO: Optimise for MTTR

DO: Adopt consistent architecture patterns

DO: Continuous delivery

DON’T: Build user-specific services

DON’T: Over disaggregate services

DON’T: Build multiple services out of the same image…

Page 17: Microservices: Lessons Learned

Questions?

Page 18: Microservices: Lessons Learned

We’re hiring!London BerlinSan Francisco