Micro services may not be the best idea

25
SAMUEL ROZE MICRO-SERVICES (MAYBE NOT) A GREAT IDEA

Transcript of Micro services may not be the best idea

Page 1: Micro services may not be the best idea

SAMUEL ROZE

MICRO-SERVICES(MAYBE NOT)

A GREAT IDEA

Page 2: Micro services may not be the best idea

2

WHY THIS TALK?I SPENT A FEW YEARS BUILDING MICRO-SERVICES BASED APPLICATIONS

Samuel Roze

PHP Software Engineering background

and consultancy. Worked with micro-

services architectures and containers to

help development teams' velocity.

ContinuousPipe.io

Continuous deployment pipeline for

containerised applications. Kubernetes-

powered PaaS. Increase your

development team velocity and the

collaboration between the technical and

business project members.

Page 3: Micro services may not be the best idea

3

A GROWING ARCHITECTURENUMBER OF MICRO-SERVICES

0

3

6

9

12

2015 Aug Oct Dec Feb Apr June Aug Oct Dec Jan Mar May Jul

Page 4: Micro services may not be the best idea

3

A GROWING ARCHITECTURENUMBER OF MICRO-SERVICES

0

3

6

9

12

2015 Aug Oct Dec Feb Apr June Aug Oct Dec Jan Mar May Jul

Page 5: Micro services may not be the best idea

4

ARCHITECTURE OVERVIEWA LONG JOURNEY TO GET TO THESE SERVICES

accountuser-interface

river

pipe

k8s-watcher

cluster-health-checker

gcb-builderbuilder

logstream

kube-proxy

kube-status

dashboard

Page 6: Micro services may not be the best idea

4

ARCHITECTURE OVERVIEWA LONG JOURNEY TO GET TO THESE SERVICES

accountuser-interface

river

pipe

k8s-watcher

cluster-health-checker

gcb-builderbuilder

logstream

kube-proxy

kube-status

dashboard

Page 7: Micro services may not be the best idea

4

ARCHITECTURE OVERVIEWA LONG JOURNEY TO GET TO THESE SERVICES

accountuser-interface

river

pipe

k8s-watcher

cluster-health-checker

gcb-builderbuilder

logstream

kube-proxy

kube-status

dashboard

Page 8: Micro services may not be the best idea

4

accountuser-interface

river

pipe

k8s-watcher

cluster-health-checker

gcb-builderbuilder

logstream

kube-proxy

kube-status

dashboard

Page 9: Micro services may not be the best idea

4

accountuser-interface

river

pipe

k8s-watcher

cluster-health-checker

gcb-builderbuilder

logstream

kube-proxy

kube-status

dashboard

github docker-hub bitbucket firebase

...

Page 10: Micro services may not be the best idea

4

accountuser-interface

river

pipe

k8s-watcher

cluster-health-checker

gcb-builderbuilder

logstream

kube-proxy

kube-status

dashboard

github docker-hub bitbucket firebase

...

Page 11: Micro services may not be the best idea

5

WHEN WE SAID "TOO MUCH"CHANGING THE BILLING MODEL

accountriver

Page 12: Micro services may not be the best idea

5

WHEN WE SAID "TOO MUCH"CHANGING THE BILLING MODEL

accountriver

Page 13: Micro services may not be the best idea

5

WHEN WE SAID "TOO MUCH"CHANGING THE BILLING MODEL

accountriver

How much is used ?

Page 14: Micro services may not be the best idea

5

WHEN WE SAID "TOO MUCH"CHANGING THE BILLING MODEL

Page 15: Micro services may not be the best idea

6

CONSEQUENCESOF SUCH A COMPLEX INFRASTRUCTURE

OPS COSTS

had to manage multiples instances of databases,

queues and cache

Page 16: Micro services may not be the best idea

6

CONSEQUENCESOF SUCH A COMPLEX INFRASTRUCTURE

OPS COSTS ON-BOARDING

SPEED

had to manage multiples instances of databases,

queues and cache

"How can I run the platform

on my laptop?"

Page 17: Micro services may not be the best idea

6

CONSEQUENCESOF SUCH A COMPLEX INFRASTRUCTURE

OPS COSTS

CHANGECOMPLEXITYON-BOARDING

SPEED

had to manage multiples instances of databases,

queues and cache

Changes across code

repositories and different

programming languages

"How can I run the platform

on my laptop?"

Page 18: Micro services may not be the best idea

6

CONSEQUENCESOF SUCH A COMPLEX INFRASTRUCTURE

OPS COSTS

CHANGECOMPLEXITYON-BOARDING

SPEEDFAULT

TOLERANCE

had to manage multiples instances of databases,

queues and cache

Changes across code

repositories and different

programming languages

"How can I run the platform

on my laptop?"

Fault-tolerance is key, but

now applies on much more

dependencies

Page 19: Micro services may not be the best idea

6

CONSEQUENCESOF SUCH A COMPLEX INFRASTRUCTURE

OPS COSTS

CHANGECOMPLEXITY TESTS

ON-BOARDING SPEED

FAULT TOLERANCE

had to manage multiples instances of databases,

queues and cache

Changes across code

repositories and different

programming languages

Good note. No other choice

than doing TDD !

"How can I run the platform

on my laptop?"

Fault-tolerance is key, but

now applies on much more

dependencies

Page 20: Micro services may not be the best idea

1STEP

Start with a monolith. Until you are really blocked.

WHAT SHOULD WE DO?

Page 21: Micro services may not be the best idea

1STEP

2STEP

Start with a monolith. Until you are really blocked.

Use managed services, as

much as possible. We replaced

all the stateful services by

managed alternatives in Google

Cloud or compose.

WHAT SHOULD WE DO?

Page 22: Micro services may not be the best idea

3STEP

1STEP

2STEP

Start with a monolith. Until you are really blocked.

Use managed services, as

much as possible. We replaced

all the stateful services by

managed alternatives in Google

Cloud or compose.

If you really require another technology, create another

service.

WHAT SHOULD WE DO?

Page 23: Micro services may not be the best idea

3STEP

4STEP

1STEP

2STEP

Start with a monolith. Until you are really blocked.

Use managed services, as

much as possible. We replaced

all the stateful services by

managed alternatives in Google

Cloud or compose.

If you really require another technology, create another

service.

Split applications when you are

already doing hundreds of

deployments a day, and can't

deal with more developers

WHAT SHOULD WE DO?

Page 24: Micro services may not be the best idea

8

• TolerancePHP fault-tolerance library, including tracinghttps://tolerance.io

• gRPC Remote procedure call framework, for multiple languages.https://grpc.io

• IstioOpen platform to connect, manage, and secure microservices.https://istio.io

• Kubernetes Service CatalogProvision, bind and use services, regardless of their location on the cluster(s).https://github.com/kubernetes-incubator/service-catalog

Page 25: Micro services may not be the best idea

9