Slide 1

Slide 1 text

Self-contained Systems: A Different Approach to Microservices

Slide 2

Slide 2 text

No content

Slide 3

Slide 3 text

http://microservices-buch.de/ http://microservices-book.com/

Slide 4

Slide 4 text

http://microservices-book.com/primer.html FREE!!!!

Slide 5

Slide 5 text

Microservice Definition

Slide 6

Slide 6 text

Server Server Microservices: Definition > Independent deployment units > E.g. process, VMs, Docker containers > Any technology > Any infrastructure Micro Service Micro Service

Slide 7

Slide 7 text

Components Collaborate Micro Service Micro Service Link Data Replication REST Messaging

Slide 8

Slide 8 text

Online Shop Order Catalog Search Billing Customer HTML / HTTP

Slide 9

Slide 9 text

Distributed System

Slide 10

Slide 10 text

Distributed System Why??

Slide 11

Slide 11 text

Why Microservices? Strong Modularization Scaling Agile Sustainable development Replaceable Services Continuous Delivery Free choice of technology Handle Legacy efficient Independent Scaling Robustness Small teams develop and deploy independently Add services – not code Small Services Failure limited to single Microservice

Slide 12

Slide 12 text

Why Microservices? Scaling Agile Sustainable development Continuous Delivery Free choice of technology Handle Legacy efficient Independent Scaling Robustness Organization Deployment Units Technology

Slide 13

Slide 13 text

Single Developer Scaling Agile Sustainable development Continuous Delivery Free choice of technology Handle Legacy efficient Independent Scaling Robustness Organization Deployment Units Technology

Slide 14

Slide 14 text

Replace Monolith Scaling Agile Sustainable development Continuous Delivery Free choice of technology Handle Legacy efficient Independent Scaling Robustness Organization Deployment Units Technology

Slide 15

Slide 15 text

Self-Contained System (SCS)

Slide 16

Slide 16 text

Deployment monolith Graphics by Roman Stranghöhner, innoQ http://scs-architecture.org

Slide 17

Slide 17 text

Various Domains

Slide 18

Slide 18 text

User interface Business logic Persistence

Slide 19

Slide 19 text

… a lot of modules, components, frameworks and libraries

Slide 20

Slide 20 text

With all these layers in one place, a monolith tends to grow.

Slide 21

Slide 21 text

Cut Deployment monolith along domains …

Slide 22

Slide 22 text

… wrap domain in separate web application …

Slide 23

Slide 23 text

Self-contained System (SCS) – individually deployable

Slide 24

Slide 24 text

Decentralized unit communicating with other systems via RESTful HTTP or lightweight messaging.

Slide 25

Slide 25 text

SCS can be individually developed for different platforms.

Slide 26

Slide 26 text

An SCS contains its own user interface, specific business logic and separate data storage

Slide 27

Slide 27 text

Web user interface composed according to ROCA principles. http://roca-style.org

Slide 28

Slide 28 text

optional API e.g. for mobile

Slide 29

Slide 29 text

Logic only shared over a well defined interface.

Slide 30

Slide 30 text

Business logic can consist of microservices

Slide 31

Slide 31 text

Every SCS brings its own data storage with ist own (potentially redundant) data

Slide 32

Slide 32 text

Redundancies: tolerable as long as sovereignty of data by owning system is not undermined.

Slide 33

Slide 33 text

Enables polyglot persistence Neo4J CouchDB Oracle

Slide 34

Slide 34 text

Technical decisions can be made independently from other systems (programming language, frameworks, tooling, platform)

Slide 35

Slide 35 text

Domain scope enables development, operation and maintenance of SCS by a single team. Team 1 Team 2 Team 3

Slide 36

Slide 36 text

Self-contained Systems should be integrated in the web interface

Slide 37

Slide 37 text

Hyperlinks to navigate between systems. System 1 System 2

Slide 38

Slide 38 text

System 1 System 2 Redirection > Use of callback URIs > As seen e.g. in OAuth flows

Slide 39

Slide 39 text

Dynamic inclusion of content served by another application System 1 System 2

Slide 40

Slide 40 text

Synchronous remote calls inside the business logic should be avoided.

Slide 41

Slide 41 text

Asynchronous Remote calls reduce dependencies and prevent error cascades.

Slide 42

Slide 42 text

Data model’s consistency guarantees are relaxed.

Slide 43

Slide 43 text

An integrated system of systems like this has many benefits.

Slide 44

Slide 44 text

Resilience is improved through loosely coupled, replaceable systems.

Slide 45

Slide 45 text

SCSs can be individually scaled to serve varying demands.

Slide 46

Slide 46 text

No risky big bang to migrate an outdated, monolithic system into a system of systems. Version 1 Version 2

Slide 47

Slide 47 text

Migration in small, manageable steps which minimize risk of failure and lead to an evolutionary modernization of big and complex systems.

Slide 48

Slide 48 text

1 *Microservice SCS

Slide 49

Slide 49 text

Conclusion > SCS: autonomouos web application > Might consist of Microservices > Focus on UI Integration > Almost completet independence > Coarse-grained architecture approach

Slide 50

Slide 50 text

Conclusion > Self-contained systems are Microservices … > that are not “micro”… > and don’t have to be “services” > Many are doing it already!

Slide 51

Slide 51 text

> http://scs- architecture.org > Creative commons > Source on Github > Slidedeck