Top Banner
ROBIN FERNANDES MICROS TEAM LEAD ATLASSIAN @REWBS Art of PaaS: Lessons learned running “Micros”, a platform for hundreds of microservices
43

AtlasCamp 2016: Art of PaaS - Lessons learned running a platform for hundreds of microservices

Apr 12, 2017

Download

Software

Robin Fernandes
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: AtlasCamp 2016: Art of PaaS - Lessons learned running a platform for hundreds of microservices

ROBIN FERNANDES • MICROS TEAM LEAD • ATLASSIAN • @REWBS

Art of PaaS:Lessons learned running “Micros”,

a platform for hundreds of microservices

Page 2: AtlasCamp 2016: Art of PaaS - Lessons learned running a platform for hundreds of microservices

Microservices,PaaS

&Connect

Page 3: AtlasCamp 2016: Art of PaaS - Lessons learned running a platform for hundreds of microservices

PaaS Overview

•‿•> <

Page 4: AtlasCamp 2016: Art of PaaS - Lessons learned running a platform for hundreds of microservices

PaaS Overview

CloudFormation RDS S3 DynamoDB

EC2

Page 5: AtlasCamp 2016: Art of PaaS - Lessons learned running a platform for hundreds of microservices

Over

services running right now

430

Page 6: AtlasCamp 2016: Art of PaaS - Lessons learned running a platform for hundreds of microservices

• Big cool statistic

• 2,569

• Add-Ons in Marketplace

Todo: better image

Why do we need a Platform?

Page 7: AtlasCamp 2016: Art of PaaS - Lessons learned running a platform for hundreds of microservices

Data Centre

JIRA & Confluence Cloud Architecture

R a c k

Cloud instance in OpenVZ container

Page 8: AtlasCamp 2016: Art of PaaS - Lessons learned running a platform for hundreds of microservices

Atlassian Connect

== Service

Decomposition

Page 9: AtlasCamp 2016: Art of PaaS - Lessons learned running a platform for hundreds of microservices

Breaking up the Monoliths

* *

Data Centre

R a c k

BlobStore service

PaaS

Page 10: AtlasCamp 2016: Art of PaaS - Lessons learned running a platform for hundreds of microservices

Breaking up the Monoliths

> <

Data Centre

R a c k

PaaS

_ _ - - /oo\

o o

. .

Page 11: AtlasCamp 2016: Art of PaaS - Lessons learned running a platform for hundreds of microservices

The platform is set to grow

PaaS

Page 12: AtlasCamp 2016: Art of PaaS - Lessons learned running a platform for hundreds of microservices

• Big cool statistic

• 2,569

• Add-Ons in Marketplace

Todo: better image

What does the platform do?

Page 13: AtlasCamp 2016: Art of PaaS - Lessons learned running a platform for hundreds of microservices

+ SD{ }Artifact Descriptor

Deploying a Service

Page 14: AtlasCamp 2016: Art of PaaS - Lessons learned running a platform for hundreds of microservices

Deploying a Servicename: Micros Workshop

description: A sample app

links:

binary:

type: npm

artifactId: '@atlassian/micros-workshop'

version: 0.0.1

healthcheck:

uri: /healthcheck

source:

url: 'ssh://[email protected]/x.git'

notifications:

email: [email protected]

owners:

- [email protected]

organization: Engineering Services

Page 15: AtlasCamp 2016: Art of PaaS - Lessons learned running a platform for hundreds of microservices

+ SD{ }Artifact Descriptor

https://<service>.atlassian.io

Deploying a Service

Compute: CloudFormation stack with: • Route 53 DNS record • Elastic Load Balancer • EC2 instances in Autoscaling group

Resources: • S3, RDS, DynamoDB • Redis, Memcached, SQS…

Page 16: AtlasCamp 2016: Art of PaaS - Lessons learned running a platform for hundreds of microservices

Logging & Monitoring

AWSCloudWatch

https://<service>.atlassian.io

Page 17: AtlasCamp 2016: Art of PaaS - Lessons learned running a platform for hundreds of microservices

. .

cloudymccloudface.atlassian.io

> micros service:deploy my-service -f service-descriptor.yml

Deploying a Service

Page 18: AtlasCamp 2016: Art of PaaS - Lessons learned running a platform for hundreds of microservices

• Big cool statistic

• 2,569

• Add-Ons in Marketplace

Lessons learned: Balancing consistency & flexibility

Page 19: AtlasCamp 2016: Art of PaaS - Lessons learned running a platform for hundreds of microservices

Where to favor rules & consistency?

Enforce: Common logging & monitoring infra

Encourage: Structured log data

Page 20: AtlasCamp 2016: Art of PaaS - Lessons learned running a platform for hundreds of microservices

Structured Log Data

Page 21: AtlasCamp 2016: Art of PaaS - Lessons learned running a platform for hundreds of microservices

Where to favor rules & consistency?

Enforce: Common logging & monitoring infra

Encourage: Structured log data

Enforce: Standard upgrade flow

Page 22: AtlasCamp 2016: Art of PaaS - Lessons learned running a platform for hundreds of microservices

https://<service>.atlassian.io

Common Upgrade flow

v1 v2

Page 23: AtlasCamp 2016: Art of PaaS - Lessons learned running a platform for hundreds of microservices

Where to favor rules & consistency?

Enforce: Common logging & monitoring infra

Encourage: Structured log data

Enforce: Standard upgrade flow

Enforce: Limited set of persistent data stores

Page 24: AtlasCamp 2016: Art of PaaS - Lessons learned running a platform for hundreds of microservices
Page 25: AtlasCamp 2016: Art of PaaS - Lessons learned running a platform for hundreds of microservices

Where to favor rules & consistency?

Enforce: Common logging & monitoring infra

Encourage: Structured log data

Enforce: Standard upgrade flow

Enforce: Limited set of persistent data stores

Encourage:Resource isolation

Page 26: AtlasCamp 2016: Art of PaaS - Lessons learned running a platform for hundreds of microservices

Resource IsolationServiceB.atlassian.io

Datastores

ServiceA.atlassian.io

Datastores

Page 27: AtlasCamp 2016: Art of PaaS - Lessons learned running a platform for hundreds of microservices

Where to favor rules & consistency?

Enforce: Common logging & monitoring infra

Encourage: Structured log data

Enforce: Standard upgrade flow

Enforce: Limited set of persistent data stores

Enforce: Common service metadata& cost allocation

Encourage:Resource isolation

Page 28: AtlasCamp 2016: Art of PaaS - Lessons learned running a platform for hundreds of microservices

Where to favor rules & consistency?

Enforce: Common logging & monitoring infra

Encourage: Structured log data

Enforce: Standard upgrade flow

Enforce: Limited set of persistent data stores

Enforce: Restricted ssh access

Enforce: Common service metadata& cost allocation

Encourage:Resource isolation

Page 29: AtlasCamp 2016: Art of PaaS - Lessons learned running a platform for hundreds of microservices

Where to favor rules & consistency?

Enforce: Common logging & monitoring infra

Encourage: Structured log data

Enforce: Standard upgrade flow

Enforce: Limited set of persistent data stores

Enforce: Statelessness & disposable compute nodes

Enforce: Restricted ssh access

Encourage:Resource isolation

Enforce: Common service metadata& cost allocation

Page 30: AtlasCamp 2016: Art of PaaS - Lessons learned running a platform for hundreds of microservices

12 Factor(not pets)

Nodes as cattle (not pets)

Page 31: AtlasCamp 2016: Art of PaaS - Lessons learned running a platform for hundreds of microservices

Where to bend the rules / favor flexibility?

Enable: Service-level technology stack flexibility

Page 32: AtlasCamp 2016: Art of PaaS - Lessons learned running a platform for hundreds of microservices

Servicesby

Runtime

Python 5%

Node.js 15%

JVM 25%

Docker 55%

Page 33: AtlasCamp 2016: Art of PaaS - Lessons learned running a platform for hundreds of microservices

Where to bend the rules / favor flexibility?

Enable: Service-level technology stack flexibility

Enable: Integration with 3rd party services

Page 34: AtlasCamp 2016: Art of PaaS - Lessons learned running a platform for hundreds of microservices

Where to bend the rules / favor flexibility?

Enable: Service-level technology stack flexibility

Adapt to underlying platform limitations

Enable: Integration with 3rd party services

Page 35: AtlasCamp 2016: Art of PaaS - Lessons learned running a platform for hundreds of microservices

Where to bend the rules / favor flexibility?

Enable: Service-level technology stack flexibility

Adapt: Education& on-boarding

Adapt to underlying platform limitations

Enable: Integration with 3rd party services

Page 36: AtlasCamp 2016: Art of PaaS - Lessons learned running a platform for hundreds of microservices

Where to bend the rules / favor flexibility?

Enable: Service-level technology stack flexibility

Adapt: Education & on-boarding

Adapt to underlying platform limitations

Enable: Integration with 3rd party services

Open the platform for contributions

Page 37: AtlasCamp 2016: Art of PaaS - Lessons learned running a platform for hundreds of microservices

Contributions&

Self-hosted PaaS components

BootstrappingService

Deploymentorchestration

service

ChaosMonkey

Log AnalysisService

PaaS

PaaS

PaaS

PaaS

PaaS

Simple Workflow

integration

Service cost estimation

Data PipelinesIntegration

Service-to-service auth

Page 38: AtlasCamp 2016: Art of PaaS - Lessons learned running a platform for hundreds of microservices

Where to bend the rules / favor flexibility?

Enable: Service-level technology stack flexibility

Adapt to underlying platform limitations

Enable: Integration with 3rd party services

Adapt: roadmap to inbound requests & technology trends

Open the platform for contributions

Adapt: Education & on-boarding

Page 39: AtlasCamp 2016: Art of PaaS - Lessons learned running a platform for hundreds of microservices

Organisation wide: Disaster Recovery

Compliance

Infra improvements: Container Clusters

Serverless

Page 40: AtlasCamp 2016: Art of PaaS - Lessons learned running a platform for hundreds of microservices

Promises of Service Decomposition

Choice oftech stacks

Scalability Independent deployments

Resilience End-to-endownership

Your platform should enable them – with heart and balance.

PaaS

Page 41: AtlasCamp 2016: Art of PaaS - Lessons learned running a platform for hundreds of microservices

Healthy PaaS —> Happy Microservices!

Balance consistencywith flexibility

Encourage / enforce“12 factor” & “nodes as cattle”

Keep the barrier toentry low

Tips for a healthy, balanced PaaS & a happy microservice ecosystem.

Page 42: AtlasCamp 2016: Art of PaaS - Lessons learned running a platform for hundreds of microservices

ROBIN FERNANDES • MICROS TEAM LEAD • ATLASSIAN • @REWBS

Thank you!

Page 43: AtlasCamp 2016: Art of PaaS - Lessons learned running a platform for hundreds of microservices

Reuters. Chickens perch on the roof of a hennery to escape rising floodwaters after Typhoon Utor hit Maoming, Guangzhou province August 15, 2013. Typhoon Utor hit China's southern Guangdong and Guangxi provinces before easing to a tropical storm.

Image Credits

https://design.atlassian.com/

Courtesy of Scott Monday:- https://au.pinterest.com/pin/146085581635905884/- http://scottmonday.com/

Copyright: velvetocean / 123RF Stock Photo – http://www.123rf.com/profile_velvetocean

Copyright: feedough / 123RF Stock Photo – http://www.123rf.com/profile_feedough'

Copyright: iimages / 123RF Stock Photo – http://www.123rf.com/iimages_feedough