design patterns for scalable apis based on docker

25
Design Patterns for Scalable APIs Based on Docker @stoitsev

Upload: nikolay-stoitsev

Post on 16-Apr-2017

105 views

Category:

Software


0 download

TRANSCRIPT

Page 1: Design Patterns for Scalable APIs based on Docker

Design Patterns for Scalable APIs Based on Docker

@stoitsev

Page 2: Design Patterns for Scalable APIs based on Docker

docker run ufaldsg/cloud-asr-api

Page 3: Design Patterns for Scalable APIs based on Docker

https://www.dockerbook.com/

Page 4: Design Patterns for Scalable APIs based on Docker

Class

Object

Image

Container

Page 5: Design Patterns for Scalable APIs based on Docker
Page 6: Design Patterns for Scalable APIs based on Docker

Map/Reduce

Page 8: Design Patterns for Scalable APIs based on Docker

Single-node, multi-container Application patterns

Page 9: Design Patterns for Scalable APIs based on Docker

Sidecar

Web server Log server

File System

Page 10: Design Patterns for Scalable APIs based on Docker

Sidecar

Application Instance Translations Downloader

File System

Page 11: Design Patterns for Scalable APIs based on Docker

Resource Isolation

Separate development

Easy and flexible composition

Failure containment

Page 12: Design Patterns for Scalable APIs based on Docker

Ambassador

Web Server Ambasador

External App

External App

External App

Page 13: Design Patterns for Scalable APIs based on Docker

Ambassador

Application Hyperbahn Instance

Hyperbahn Instance

Hyperbahn Instance

Hyperbahn Instance

https://github.com/uber-archive/hyperbahn

Page 14: Design Patterns for Scalable APIs based on Docker

Easy to reason about

Easy to test

Reusable

Page 15: Design Patterns for Scalable APIs based on Docker

Adapter

Application Monitoring Adapter Centralized monitoring system

Page 16: Design Patterns for Scalable APIs based on Docker

Multi-node application patterns

Page 17: Design Patterns for Scalable APIs based on Docker

Leader election

AppLeader election

container

AppLeader election

container

AppLeader election

container

AppLeader election

container

Page 18: Design Patterns for Scalable APIs based on Docker

Simplifies the problem

Easy testing

Page 19: Design Patterns for Scalable APIs based on Docker

Work queue

WorkerWork Execution

WorkerWork Execution

Work Coordinator

Page 20: Design Patterns for Scalable APIs based on Docker

Simplification

Page 21: Design Patterns for Scalable APIs based on Docker

Scatter/gather

MergeExecution

Work Execution

Work Execution

Root Work Execution

Page 22: Design Patterns for Scalable APIs based on Docker
Page 23: Design Patterns for Scalable APIs based on Docker

Idempotent

Pure

Composable

Page 24: Design Patterns for Scalable APIs based on Docker

http://eng.uber.com/

Page 25: Design Patterns for Scalable APIs based on Docker

Thanks