beyond 1001 dedicated data service instances - … service instances. introduction. the challenge....

372
Beyond 1001 Dedicated Data Service Instances

Upload: ngonhi

Post on 07-Mar-2018

218 views

Category:

Documents


2 download

TRANSCRIPT

Page 1: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Beyond 1001 Dedicated Data Service Instances

Page 2: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Introduction

Page 3: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application
Page 4: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

The Challenge

Page 5: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Given: Application platform based on

Cloud Foundry to serve thousands of apps

Page 6: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Application Runtime

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

Page 7: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

• Many platform users - who don’t

know each other

• Different app langs & frameworks

• 100% on-demand self-service: no

involvement of the platform

operator necessary.

• Instant scalablity & self-healing

Page 8: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

$> cf push myapp

Easy Deployment

Page 9: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Runtime abstraction

Page 10: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

ExecutionStagingJava

Droplet

Java

Code

Java

Bildpack

Droplet

Page 11: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

ExecutionStaging

Ruby

Bildpack

DropletRuby Ruby

Droplet

Page 12: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Droplet DropletJava

Droplet Ruby

Droplet

Page 13: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

In front of the Cloud

Foundry Runtime

all droplets are equal

Page 14: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Droplet Droplet

$START_CMD $START_CMD

Page 15: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

DropletContainer

Image

$START_CMD $START_CMD

Droplet

$START_CMD

Page 16: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Something you can

execute in a container.

Something you can

execute in a container.

$START_CMD $START_CMD

Something you can

execute in a container.

$START_CMD

Page 17: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Abstraction enables further

assumptions & automation

Page 18: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

$>

Scaling Apps

Assuming this to be our status quo.

Cloud Foundry Runtime

App#1

Instance#1

App#2

Instance#1

App#2

Instance#2

Page 19: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

$> cf scale -i 3 app#1

App Scalability

Page 20: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

$>

Scaling Apps

Cloud Foundry Runtime

App#1

Instance#1

App#1

Instance#3

App#2

Instance#1

App#2

Instance#2

App#1

Instance#2

Two additional instances have been created.

Page 21: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

App Self-Healing

Page 22: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

$>

App Self-Healing

Everything is healthy.

Cloud Foundry Runtime

App#1

Instance#1

App#1

Instance#3

App#2

Instance#1

App#2

Instance#2

App#1

Instance#2

Page 23: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

$>

Cloud Foundry Runtime

App Self-Healing

App #1 Instance #2 is failing.

App#1

Instance#1

App1

Instance

2

App#1

Instance#3

App#2

Instance#1

App#2

Instance#2

Page 24: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

$>

Cloud Foundry Runtime

App Self-Healing

App #1 Instance #2 - gone temporarily.

App#1

Instance#1

App#1

Instance#3

App#2

Instance#1

App#2

Instance#2

Page 25: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

$>

App Self-Healing

App #1 Instance #2 re-created.

Cloud Foundry Runtime

App#1

Instance#1

App#1

Instance#3

App#2

Instance#1

App#2

Instance#2

App#1

Instance#2

Page 26: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

How does the paradise for

Backing Services look

like?

Page 27: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Missing: A solution to serve thousands of

data services

Page 28: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Data ServicesApplication Runtime

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

Page 29: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

The Mission

Page 30: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Providing a growing number of data services with full lifecycle automation of

thousands of data service instances across a wide range of infrastructures

Page 31: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Providing a growing number of data services with full lifecycle automation of

thousands of data service instances across a wide range of infrastructures

Page 32: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Providing a growing number of data services with full lifecycle automation of

thousands of data service instances across a wide range of infrastructures

a9s PostgreSQL a9s MongoDB a9s RabbitMQ

a9s Elasticsearch a9s Redis a9s LogMe

Page 33: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Providing a growing number of data services with full lifecycle automation of

thousands of data service instances across a wide range of infrastructures

Page 34: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Providing a growing number of data services with full lifecycle automation of

thousands of data service instances across a wide range of infrastructures

Page 35: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Providing a growing number of data services with full lifecycle automation of

thousands of data service instances across a wide range of infrastructures.

Page 36: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Providing a growing number of data services with full lifecycle automation of

thousands of data service instances across a wide range of infrastructures.

Page 37: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Providing a growing number of data services with full lifecycle automation of

thousands of data service instances across a wide range of infrastructures

Page 38: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

in both:

Page 39: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

in both:public

Page 40: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

in both:public and on-premise clouds

Page 41: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

and integrate well with multiple platforms

Page 42: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

and integrate well with multiple platforms

Page 43: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Requirements

Page 44: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Portability

Robustness

Scalability

On-demand self-service

Performance Maintainability

Flexibility

Extensibility

Usability

Manageability

Security

Multi-tenancy

Page 45: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Portability

Scalability

On-demand self-service

Production-Readiness

Page 46: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Design

Page 47: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

How to build it?

Page 48: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Data Service Provisioning API Automation Middleware Data Service Automation

Page 49: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application
Page 50: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Open Service Broker, a new industry standard

for data service provisioning.

🔑

Page 51: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

• Google

• Pivotal

• IBM

• RedHat

• Fujitsu

• SAP

Open Service Broker API Supporters

Page 52: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

• Cloud Foundry

• OpenShift

• Kubernetes

• More to come

Supporting Platforms

Page 53: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

• Cloud Foundry

• OpenShift

• Kubernetes

• More to come

Supporting Platforms

Page 54: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

• Get Service CatalogGET /v2/catalog

• Provision Service - Create Service InstancePUT /v2/service_instances/:id

• Bind ServicePUT /v2/service_instances/:instance_id/

service_bindings/:id

• Unbind ServiceDELETE /v2/service_instances/:instance_id/

service_bindings/:id

• Unprovision ServiceDELETE /v2/service_instances/:id

http://docs.cloudfoundry.org/services/api.html#api-overview

Page 55: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

HTTP Verb Action

Service Catalog GET /v2/catalog

Deliver meta data about the data service.

Create Service Instance PUT /v2/service_instances/:id

Provision a VM, install and configure a data service VMs

/ Cluster representing a service instance.

Create Service Binding PUT /v2/service_instances/:instance_id/

service_bindings/:id

Create a data service user and return credentials representing a service

binding.

Delete Service Binding DELETE /v2/

service_instances/:instance_id/service_bindings/:id

Remove credentials associated with the service binding.

Delete Service Instance DELETE /v2/service_instances/:id

Destroy the VMs and data associated with the service instance.

Page 56: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Data Service Provisioning API Automation Middleware Data Service

Page 57: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

The Open Service Broker API does not define what a service instance is.

🔑

Page 58: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Applying the design pattern: On-Demand Provisioning

of Dedicated Data Service Instances

🔑

Page 59: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Result

Page 60: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Using a Service Broker with Cloud Foundry

$> cf create-service

Page 61: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

$> cf create-service mongodb single-small my-single-mongo-1

Easy Deployment

Page 62: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

my-single-mongo-1

MongoDB

VM#1

Page 63: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

$> cf create-service mongodb cluster-small my-3node-mongo-

cluster-2

Easy Deployment

Page 64: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Newly created service instance

my-3node-mongo-cluster-2

MongoDB

VM#1

MongoDB

VM#2

MongoDB

VM#3

my-single-mongo-1

MongoDB

VM#1

Page 65: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Technical Challenges

Page 66: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

State

Page 67: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

State is handled differently in each backing service.

Page 68: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

State is handled differently in each backing service.

Operational model will be different. Replication, failure detection, failover.

Page 69: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

State is handled differently in each backing service.

Operational model will be different. Replication, failure detection, failover.

The data service automation will be different.

Page 70: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Where to store state?

Page 71: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

App Self-Healing

Everything is healthy.

Cloud Foundry Runtime

App#1

Instance#1

App#1

Instance#3

App#2

Instance#1

App#2

Instance#2

App#1

Instance#2

Page 72: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cloud Foundry Runtime

App Self-Healing

App #1 Instance #2 is failing.

App#1

Instance#1

App1

Instance

2

App#1

Instance#3

App#2

Instance#1

App#2

Instance#2

Page 73: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cloud Foundry Runtime

App Self-Healing

App #1 Instance #2 - gone temporarily.

App#1

Instance#1

App#1

Instance#3

App#2

Instance#1

App#2

Instance#2

Page 74: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

App Self-Healing

App #1 Instance #2 re-created.

Cloud Foundry Runtime

App#1

Instance#1

App#1

Instance#3

App#2

Instance#1

App#2

Instance#2

App#1

Instance#2

Page 75: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

App self-healing is easy because there is NO STATE.

Page 76: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

App self-healing is easy because there is NO STATE.

How to store state but still being able to perform self-healing?

Page 77: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Store state on a remotely attached block device = persistent disk.

🔑

Page 78: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Infrastructure as a Service (IaaS), e.g. OpenStack

VIRTUAL DATACENTER

Router

STORAGE

Storage Node Storage Node Storage Node

HDD HDD

HDD HDD

HDD HDD

HDD HDD

HDD HDD

HDD HDD

HDD HDD

HDD HDD

HDD HDD

IaaS API

Page 79: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Infrastructure as a Service (IaaS), e.g. OpenStack

VIRTUAL DATACENTER

Router

STORAGE

Storage Node Storage Node Storage Node

HDD HDD

HDD HDD

HDD HDD

HDD HDD

HDD HDD

HDD HDD

HDD HDD

HDD HDD

HDD HDD

Storage Volume

Operating System

VIRTUAL MACHINE

IaaS API

Page 80: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Persistent disk has a file system. Filesystems may fail

⇒ replication / clustering & backupsare still very important.

Page 81: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

The data lifecycle has been decoupled from the VM lifecycle ⇒ The VM becomes disposable.

🔑

Page 82: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Storing state ✅

Page 83: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

What needs to be automated?

Page 84: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Data Service Instance Lifecycle

Page 85: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Provision a data service server Install data service software

Configure data service software Consume data service with apps

Debug data service issues Update data service version

Update operating system Backup & recover data

Scale out data service VM(s) Destroy data service & DB VM(s)

Lifecycle of a Data Service Instance1

Page 86: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Can you do that x * 1000 times?

Page 87: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

You either automate it or delegate it to the app developer.

🔑

Page 88: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Automation

Page 89: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

BOSH

Page 90: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

„BOSH let’s you orchestrate the

lifecycle of

large-scale deployments of stateful distributed systems

to infrastructure.“

Page 91: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Infrastructure as a Service (IaaS), e.g. OpenStack

VIRTUAL DATACENTER

VIRTUAL MACHINE

BOSH

Router

STORAGE

Storage Node Storage Node Storage Node

HDD HDD

HDD HDD

HDD HDD

HDD HDD

HDD HDD

HDD HDD

HDD HDD

HDD HDD

HDD HDD

BOSH API

BOSH CLI $> bosh deploy

IaaS API

BOSH CPI

Page 92: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Infrastructure as a Service (IaaS), e.g. OpenStack

VIRTUAL DATACENTER

VIRTUAL MACHINE

BOSH

Router

STORAGE

Storage Node Storage Node Storage Node

HDD HDD

HDD HDD

HDD HDD

HDD HDD

HDD HDD

HDD HDD

HDD HDD

HDD HDD

HDD HDD

BOSH API

BOSH CLI $> bosh deploy

IaaS API

BOSH CPI

Page 93: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Infrastructure as a Service (IaaS), e.g. OpenStack

VIRTUAL DATACENTER

VIRTUAL MACHINE

BOSH

Router

STORAGE

Storage Node Storage Node Storage Node

HDD HDD

HDD HDD

HDD HDD

HDD HDD

HDD HDD

HDD HDD

HDD HDD

HDD HDD

HDD HDD

BOSH API

BOSH CLI $> bosh deploy

IaaS API

BOSH CPI

Page 94: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Infrastructure as a Service (IaaS), e.g. OpenStack

VIRTUAL DATACENTER

VIRTUAL MACHINE

BOSH

Router

STORAGE

Storage Node Storage Node Storage Node

HDD HDD

HDD HDD

HDD HDD

HDD HDD

HDD HDD

HDD HDD

HDD HDD

HDD HDD

HDD HDD

BOSH API

Storage Volume

Operating System

BOSH Agent

VIRTUAL MACHINE

BOSH CLI $> bosh deploy

IaaS API

BOSH CPI

Page 95: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Infrastructure as a Service (IaaS), e.g. OpenStack

VIRTUAL DATACENTER

VIRTUAL MACHINE

BOSH

Router

STORAGE

Storage Node Storage Node Storage Node

HDD HDD

HDD HDD

HDD HDD

HDD HDD

HDD HDD

HDD HDD

HDD HDD

HDD HDD

HDD HDD

BOSH APIOperating

System

BOSH Agent

VIRTUAL MACHINE

BOSH CLI $> bosh deploy

IaaS API

BOSH CPI

Page 96: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Infrastructure as a Service (IaaS), e.g. OpenStack

VIRTUAL DATACENTER

VIRTUAL MACHINE

BOSH

Router

STORAGE

Storage Node Storage Node Storage Node

HDD HDD

HDD HDD

HDD HDD

HDD HDD

HDD HDD

HDD HDD

HDD HDD

HDD HDD

HDD HDD

BOSH APIOperating

System

BOSH Agent

VIRTUAL MACHINE

BOSH CLI $> bosh deploy

IaaS API

PostgreSQL

BOSH CPI

Page 97: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Infrastructure as a Service (IaaS), e.g. OpenStack

VIRTUAL DATACENTER

VIRTUAL MACHINE

BOSH

Router

STORAGE

Storage Node Storage Node Storage Node

HDD HDD

HDD HDD

HDD HDD

HDD HDD

HDD HDD

HDD HDD

HDD HDD

HDD HDD

HDD HDD

BOSH APIOperating

System

BOSH Agent

VIRTUAL MACHINE

BOSH CLI $> bosh deploy

IaaS API

PostgreSQL

BOSH CPI

Page 98: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Infrastructure as a Service (IaaS), e.g. OpenStack

VIRTUAL DATACENTER

VIRTUAL MACHINE

BOSH

Router

STORAGE

Storage Node Storage Node Storage Node

HDD HDD

HDD HDD

HDD HDD

HDD HDD

HDD HDD

HDD HDD

HDD HDD

HDD HDD

HDD HDD

BOSH APIOperating

System

BOSH Agent

VIRTUAL MACHINE

BOSH CLI $> bosh deploy

IaaS API

BOSH Agent

VIRTUAL MACHINE

PostgreSQL Operating System

BOSH Agent

VIRTUAL MACHINE

Cloud Controller

Operating System

BOSH Agent

VIRTUAL MACHINE

UAA

BOSH CPI

Page 99: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

BOSH Automation

Page 100: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

BOSH Releases

contain the automation

Page 101: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

A BOSH-Deployment depends on 1 .. *

Stemcells

Page 102: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

A BOSH-Deployment is described by a

Release & Manifest

Page 103: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

A Release describe 1 .. * Jobs

Page 104: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

A Release contains 1 .. * Package

Page 105: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

A BOSH Deployment’s

settings are contained in a

Manifest

Page 106: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Infrastructure settings

settings are contained in the

Cloud Config

Page 107: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

BOSH makes your

deployments…

Page 108: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Infrastructure

Independent

Page 109: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

• A BOSH release contains the

main-automation (software packages, how to run

processes)

• BOSH releases can be re-used

on every* infrastructure

Page 110: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Automate once,

deploy everywhere.

Page 111: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

VMware

BOSH

BOSH CLI

OpenStack

BOSH

AWS

BOSH

Page 112: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

VMware

BOSH

BOSH CLI

Some Service / App

BOSH Agent

VIRTUAL MACHINE

Some Service / App

BOSH Agent

VIRTUAL MACHINE

Some Service / App

BOSH Agent

VIRTUAL MACHINE

Some Service / App

BOSH Agent

VIRTUAL MACHINE

Some Service / App

BOSH Agent

VIRTUAL MACHINE

Some Service / App

BOSH Agent

VIRTUAL MACHINE

OpenStack

BOSH

AWS

BOSH

Page 113: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

BOSH CLI

VMware AWS OpenStack

BOSH BOSH BOSH

Page 114: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

BOSH CLI

VMware AWS OpenStack

$> bosh target http://bosh-on.aws.com

BOSH BOSH BOSH

Page 115: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

BOSH CLI

VMware AWS OpenStack

BOSH BOSH BOSH

Page 116: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

BOSH CLI

VMware AWS OpenStack

$> bosh deploy

BOSH BOSH BOSH

Page 117: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

BOSH CLI

VMware AWS OpenStack

Some Service / App

BOSH Agent

VIRTUAL MACHINE

Some Service / App

BOSH Agent

VIRTUAL MACHINE

Some Service / App

BOSH Agent

VIRTUAL MACHINE

Some Service / App

BOSH Agent

VIRTUAL MACHINE

Some Service / App

BOSH Agent

VIRTUAL MACHINE

Some Service / App

BOSH Agent

VIRTUAL MACHINE

BOSH BOSH BOSH

Page 118: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

• Switch deployment between

clouds

• Keep the same release

• Use a stemcell specific to the

new cloud

• Adapt the cloud config

Page 119: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Operating System

Independent

Page 120: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

A BOSH release does

not depend on the OS

Page 121: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

The only dependency to

the OS is a BOSH

stemcell

Page 122: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Operating System Image

BOSH Agent

VIRTUAL MACHINE

Page 123: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Operating System Image

BOSH Agent

VIRTUAL MACHINE

}

Page 124: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Operating System Image

BOSH Agent

VIRTUAL MACHINE

} OS image +BOSH agent= Stemcell

Page 125: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Ubuntu Stemcell

BOSH Agent

VIRTUAL MACHINE

Page 126: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

• Changing the OS of a BOSH

deployed system

• Keep the same release

• Change the stemcell

• Change the manifest

Page 127: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Scalable

Page 128: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Horizontal Scaling

Page 129: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Horizontal Scaling

Some Service

BOSH Agent

VIRTUAL MACHINE

Some Service

BOSH Agent

VIRTUAL MACHINE

Some Service

BOSH Agent

VIRTUAL MACHINE

Some Service

BOSH Agent

VIRTUAL MACHINE

Some Service

BOSH Agent

VIRTUAL MACHINE

Some Service

BOSH Agent

VIRTUAL MACHINE

Some Service

BOSH Agent

VIRTUAL MACHINE

Some Service

BOSH Agent

VIRTUAL MACHINE

Some Service

BOSH Agent

VIRTUAL MACHINE

Some Service

BOSH Agent

VIRTUAL MACHINE

Some Service

BOSH Agent

VIRTUAL MACHINE

Some Service

BOSH Agent

VIRTUAL MACHINE

Some Service

BOSH Agent

VIRTUAL MACHINE

Some Service

BOSH Agent

VIRTUAL MACHINE

Some Service

BOSH Agent

VIRTUAL MACHINE

Some Service

BOSH Agent

VIRTUAL MACHINE

Some Service

BOSH Agent

VIRTUAL MACHINE

Some Service

BOSH Agent

VIRTUAL MACHINE

Some Service

BOSH Agent

VIRTUAL MACHINE

Some Service

BOSH Agent

VIRTUAL MACHINE

Some Service

BOSH Agent

VIRTUAL MACHINE

Some Service

BOSH Agent

VIRTUAL MACHINE

Some Service

BOSH Agent

VIRTUAL MACHINE

Some Service

BOSH Agent

VIRTUAL MACHINE

Some Service

BOSH Agent

VIRTUAL MACHINE

Some Service

BOSH Agent

VIRTUAL MACHINE

Some Service

BOSH Agent

VIRTUAL MACHINE

Some Service

BOSH Agent

VIRTUAL MACHINE

Page 130: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

• Scaling-out a BOSH deployed

system

• Keep the same release

• Use the same stemcell

• Change the manifest

Page 131: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Vertical Scaling

Page 132: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

4GB RAM 1 vCPU

10GB persistent disk

BOSH Agent

VIRTUAL MACHINE 4 GB RAM, 1 vCPU

10 GB Persistent Disk

Data

PostgreSQL

Page 133: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

BOSH Agent

VIRTUAL MACHINE 4 GB RAM, 1 vCPU

PostgreSQL

10 GB Persistent Disk

Data

Page 134: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

BOSH Agent

VIRTUAL MACHINE 4 GB RAM, 1 vCPU

PostgreSQL

Page 135: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

BOSH Agent

PostgreSQL

VIRTUAL MACHINE 8 GB RAM, 2 vCPUs

10 GB Persistent Disk

Data

20 GB Persistent Disk

Data

Page 136: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

BOSH Agent

PostgreSQL

VIRTUAL MACHINE 8 GB RAM, 2 vCPUs

10 GB Persistent Disk

Data

20 GB Persistent Disk

Data

Page 137: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

BOSH Agent

PostgreSQL

VIRTUAL MACHINE 8 GB RAM, 2 vCPUs

20 GB Persistent Disk

Data

Page 138: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

BOSH Deployments are Predictable

Page 139: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

• Src code is compiled in a freshly

created VMs

• VMs always contain exact the

software, specified in the release

• No left-overs of prior

deployments as new VMs are

used.

Page 140: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

BOSH Deployments are

Repeatable

Page 141: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Executing a specific BOSH deployment always leads to exact same deployed system.

🔑

Page 142: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Monitored &Self-Healing

Page 143: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Self-healingprocess failures

Page 144: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

BOSH Installation BOSH Managed Infrastructure Resources

Some process

BOSH Agent

VIR

TU

AL

MA

CH

INE

Process Monitor

Yet another process

VIR

TU

AL

MA

CH

INE

BOSH Agent

BOSH Health Monitor

BOSH Director

NATS Message Bus

Some other process

VIR

TU

AL

MA

CH

INE

BOSH Agent Process Monitor

BOSH Registry

BLOB Store

🎖

🗃

🗄

📡

CP

I

Process MonitorProcess Monitor

Page 145: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

BOSH Installation BOSH Managed Infrastructure Resources

Some process

BOSH Agent

VIR

TU

AL

MA

CH

INE

Process Monitor

Yet another process

VIR

TU

AL

MA

CH

INE

BOSH Agent

BOSH Health Monitor

BOSH Director

NATS Message Bus

VIR

TU

AL

MA

CH

INE

BOSH Agent Process Monitor

BOSH Registry

BLOB Store

🎖

🗃

🗄

📡

CP

I

Some other process

Process MonitorProcess Monitor

Page 146: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Self-healingprocess monitor failures

Page 147: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

BOSH Installation BOSH Managed Infrastructure Resources

Some process

BOSH Agent

VIR

TU

AL

MA

CH

INE

Process Monitor

Yet another process

VIR

TU

AL

MA

CH

INE

BOSH Agent

BOSH Health Monitor

BOSH Director

NATS Message Bus

Some other process

VIR

TU

AL

MA

CH

INE

BOSH Agent Process Monitor

BOSH Registry

BLOB Store

🎖

🗃

🗄

📡

CP

I

Some other process

Process MonitorProcess Monitor

Page 148: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

BOSH Installation BOSH Managed Infrastructure Resources

Some process

BOSH Agent

VIR

TU

AL

MA

CH

INE

Yet another process

VIR

TU

AL

MA

CH

INE

BOSH Agent

BOSH Health Monitor

BOSH Director

NATS Message Bus

Some other process

VIR

TU

AL

MA

CH

INE

BOSH Agent Process Monitor

BOSH Registry

BLOB Store

🎖

🗃

🗄

📡

CP

I

Some other process

Process MonitorProcess Monitor

Page 149: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

BOSH Installation BOSH Managed Infrastructure Resources

Some process

BOSH Agent

VIR

TU

AL

MA

CH

INE

Yet another process

VIR

TU

AL

MA

CH

INE

BOSH Agent

BOSH Health Monitor

BOSH Director

NATS Message Bus

Some other process

VIR

TU

AL

MA

CH

INE

BOSH Agent Process Monitor

BOSH Registry

BLOB Store

🎖

🗃

🗄

📡

CP

I

Some other process

Process MonitorProcess Monitor

Page 150: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

BOSH Installation BOSH Managed Infrastructure Resources

Some process

BOSH Agent

VIR

TU

AL

MA

CH

INE

Yet another process

VIR

TU

AL

MA

CH

INE

BOSH Agent

BOSH Health Monitor

BOSH Director

NATS Message Bus

Some other process

VIR

TU

AL

MA

CH

INE

BOSH Agent Process Monitor

BOSH Registry

BLOB Store

🎖

🗃

🗄

📡

CP

I

Some other process

Process MonitorProcess Monitor

Process Monitor

Page 151: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Self-healingVM failures

Page 152: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

BOSH Installation BOSH Managed Infrastructure Resources

Some process

BOSH Agent

VIR

TU

AL

MA

CH

INE

Process Monitor

Yet another process

VIR

TU

AL

MA

CH

INE

BOSH Agent Process Monitor

NATS Message Bus

Some other process

VIR

TU

AL

MA

CH

INE

BOSH Agent Process Monitor

Process Monitor

BOSH Registry

BLOB Store

🗃

🗄

📡

🎖 BOSH Director

CP

I

BOSH Health Monitor❤

Page 153: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

BOSH Installation BOSH Managed Infrastructure Resources

Some process

BOSH Agent

VIR

TU

AL

MA

CH

INE

Process Monitor

Yet another process

VIR

TU

AL

MA

CH

INE

BOSH Agent Process Monitor

NATS Message Bus

Process Monitor

BOSH Registry

BLOB Store

🗃

🗄

📡

🎖 BOSH Director

CP

I

Some other process

VIR

TU

AL

MA

CH

INE

BOSH Agent Process Monitor

BOSH Health Monitor❤

Page 154: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Self-healingBOSH Agent failures

Page 155: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

BOSH Managed Infrastructure Resources

Yet another process

VIR

TU

AL

MA

CH

INE

Process Monitor

BOSH Installation

Some process

BOSH Agent

VIR

TU

AL

MA

CH

INE

Process Monitor

BOSH Agent

NATS Message Bus

Some other process

VIR

TU

AL

MA

CH

INE

BOSH Agent Process Monitor

BOSH Registry

BLOB Store

🗃

🗄

📡

🎖 BOSH Director

CP

I

BOSH Agent

BOSH Health Monitor❤

Page 156: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

BOSH Managed Infrastructure Resources

BOSH Installation

Some process

BOSH Agent

VIR

TU

AL

MA

CH

INE

Process Monitor

NATS Message Bus

Some other process

VIR

TU

AL

MA

CH

INE

BOSH Agent Process Monitor

BOSH Registry

BLOB Store

🗃

🗄

📡

🎖 BOSH Director

CP

I

BOSH Agent

BOSH Health Monitor❤

Yet another process

VIR

TU

AL

MA

CH

INE

Process MonitorBOSH Agent

Page 157: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Data Service Provisioning API Automation Middleware Data Service Automation

Page 158: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Reference Architecture

Page 159: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

a9s Deployer

Templates Deployments

Bosh

a9s Service Broker

my-3node-postgres-cluster-2

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3

my-single-postgres-1

Postgresql

VM#1

Middleware Adapter

Cloud Foundry Adapter

a9s PostgreSQL SPI

Service InstanceService Instance

my-3node-postgres-cluster-3

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3

Service Instance

Cloud ControllerCF Clientcreate service

create service

create deployment from template xy with attributes {…}

deploy release abc & deployment manifest xyz

Execute deployments

create

service specific credentials

create binding

Page 160: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Data Service Provisioning API Automation Middleware Data Service Automation

Page 161: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

PortabilityBOSH:

Multi-infrastructure support

Open Service Broker API:

Multi-platform support

Scalability On-demand provisioning of dedicated service instances

BOSH: Scale existing service instances

vertically, solo & clustered

instances

Production Readyness

Dedicated data service instances / Strong instance

isolation

BOSH: Self-healing, clustered service

instances, backup & restore

On-demand self-service

Open Service Broker API, On-demand provisioning, on-

demand updatesOn-demand backup &

restore

Page 162: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

a9s PostgreSQL a9s MongoDB a9s RabbitMQ

a9s Elasticsearch a9s Redis a9s LogMe

Page 163: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Operations

Page 164: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Continuous Data Service Delivery

Page 165: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Testa9s

Release

Delivering Data Service Patches

BuildUpstream

Release

Platform #1

Platform #2

Platform #n

Updating the Data Services

Update Data Service Instances

a9s PostgreSQLOpen Source

PostgreSQL Building new Data Service Releases

Page 166: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Common Maintenance Tasks to performed at Scale

Page 167: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

• Create VM

• Install and start data services

Create Service Instance

Page 168: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

• Destroy old VM

• Create new VM

• Mount old persistent disk

• Create and mount new persistent disk

• Copy data

• Optional: reintegrate into the cluster

Vertical Scale Service Instance

Page 169: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

• Destroy old VM

• Create new VM based on new

Stemcell (\w new OS version)

• Attach persistent disk

OS Update

Page 170: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Ultimate Question

Page 171: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Can you handle more than 1001 Data Service Instances?

Page 172: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Yes.

Page 173: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Excerpt from our perf tests:

Page 174: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Provisioning 1001 instances in sequence over a greater period of time does not

expose any significant bottleneck.

Page 175: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

For large highly-frequented platforms the amount of simultaneous deployments

may become relevant.

Page 176: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Data Service Instances

BOSH Queue Time

Avg. time to provision VM

Total time needed to

create instances

250 14 min 6:57 min 21 min

500 29 min 7:01 36 min

750 46 min 7:13 53 min

… … … …

Page 177: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Optimization Task: Manage BOSH queueing time to an acceptable

level.

Page 178: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Scaling BOSH is key to deal with simultaneous provisioning.

Page 179: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Sum Up

Page 180: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

• Full lifecycle automation is feasible

• Open Service Broker API, a new

standard

• Choosing the right automation

technology is key, e.g. BOSH

• CI/CD based dev and ops are essential

Sum Up

Page 181: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Questions?

Page 182: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

A. Shared VM cluster

B. Dedicated containers

C. Dedicated VMs / VM clusters

Common Data Service Design Patterns

Page 183: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Scaling a shared VM cluster

Page 184: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

3 VMs

MongoDB Cluster

MongoDB VM #1 MongoDB VM #2 MongoDB VM #3

Scaling a shared VM cluster

Page 185: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

3 VMs

MongoDB Cluster

MongoDB VM #1 MongoDB VM #2 MongoDB VM #3

Scaling a shared VM cluster

Page 186: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

3 VMs

MongoDB Cluster

MongoDB VM #1 MongoDB VM #2 MongoDB VM #3

Service Instance #1 = database #1

Service Instance #2 = database #2

Service Instance #3 = database #3

Service Instance #4 = database #4

Service Instance #5 = database #5

Service Instance #6 = database #6

Service Instance #… = database #…

Service Instance # n-max = database #n-max

Scaling a shared VM cluster

Page 187: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

3 VMs

MongoDB Cluster

MongoDB VM #1 MongoDB VM #2 MongoDB VM #3

Service Instance #1 = database #1

Service Instance #2 = database #2

Service Instance #3 = database #3

Service Instance #4 = database #4

Service Instance #5 = database #5

Service Instance #6 = database #6

Service Instance #… = database #…

Service Instance # n-max = database #n-max

Scaling a shared VM cluster

Page 188: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Low costs per service instance

Scaling a shared VM cluster

Page 189: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Simple Service Broker Logic

Scaling a shared VM cluster

Page 190: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

create service → create a database

Page 191: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

create service binding → create a database user

Page 192: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Weak Isolation!

Page 193: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Structural Limitation!

Page 194: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

What to do when the shared cluster is full?

Scaling a shared VM cluster

Page 195: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

MongoDB VM #1 MongoDB VM #2 MongoDB VM #3

Service Instance #1 = database #1

Service Instance #2 = database #2

Service Instance #3 = database #3

Service Instance #4 = database #4

Service Instance #5 = database #5

Service Instance #6 = database #6

Service Instance #… = database #…

Service Instance # n-max = database #n-max

Scaling a shared VM cluster

3 VMs

MongoDB Cluster

Service Instance #1 = database #1

Service Instance #2 = database #2

Service Instance #3 = database #3

Service Instance #4 = database #4

Service Instance #5 = database #5

Service Instance #6 = database #6

Service Instance #… = database #…

Service Instance # n-max = database #n-max

Page 196: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

3 VMs

MongoDB VM #1 MongoDB VM #2 MongoDB VM #3

MongoDB Cluster #1

Service Instance #1 = database #1

Service Instance #2 = database #2

Service Instance #3 = database #3

Service Instance #4 = database #4

Service Instance #5 = database #5

Service Instance #6 = database #6

Service Instance #… = database #…

Service Instance # n-max = database #n-max

Scaling a shared VM cluster

3 VMs

MongoDB Cluster

Service Instance #1 = database #1

Service Instance #2 = database #2

Service Instance #3 = database #3

Service Instance #4 = database #4

Service Instance #5 = database #5

Service Instance #6 = database #6

Service Instance #… = database #…

Service Instance # n-max = database #n-max

Page 197: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

3 VMs

MongoDB VM #1 MongoDB VM #2 MongoDB VM #3

MongoDB Cluster #1

Service Instance #1 = database #1

Service Instance #2 = database #2

Service Instance #3 = database #3

Service Instance #4 = database #4

Service Instance #5 = database #5

Service Instance #6 = database #6

Service Instance #… = database #…

Service Instance # n-max = database #n-max

Scaling a shared VM cluster

Page 198: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

3 VMs

MongoDB VM #1 MongoDB VM #2 MongoDB VM #3

MongoDB Cluster #1

Service Instance #1 = database #1

Service Instance #2 = database #2

Service Instance #3 = database #3

Service Instance #4 = database #4

Service Instance #5 = database #5

Service Instance #6 = database #6

Service Instance #… = database #…

Service Instance # n-max = database #n-max

Scaling a shared VM cluster

3 VMs

MongoDB VM #4 MongoDB VM #5 MongoDB VM #6

MongoDB Cluster #2

Service Instance #n+1

Service Instance #n+2

Service Instance #n+3

Service Instance #n+4

Service Instance #n+5

Service Instance #n+6

Service Instance #…

Service Instance # 2*n-max

Page 199: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Service Broker Logic

Scaling a shared VM cluster

Simple

Page 200: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Service Broker Logic

Scaling a shared VM cluster

Complex

Page 201: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Fragmentation

Page 202: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Caused by frequent creation and / deletion of

service instances

Fragmentation

3 VMs

MongoDB VM #2 MongoDB VM #3

MongoDB Cluster #1

Service Instance #1 = database #1

Service Instance #2 = database #2

Service Instance #3 = database #3

Service Instance #4 = database #4

Service Instance #5 = database #5

Service Instance #6 = database #6

Service Instance #… = database #…

Service Instance # n-max = database #n-max

3 VMs

MongoDB VM #4 MongoDB VM #5 MongoDB VM #6

MongoDB Cluster #2

Service Instance #n+1

Service Instance #n+2

Service Instance #n+3

Service Instance #n+4

Service Instance #n+5

Service Instance #n+6

Service Instance #…

Service Instance # 2*n-max

Page 203: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Caused by frequent creation and / deletion of

service instances

Fragmentation

3 VMs

MongoDB VM #2 MongoDB VM #3

MongoDB Cluster #1

Service Instance #1 = database #1

Service Instance #3 = database #3

Service Instance #5 = database #5

Service Instance #… = database #…

Service Instance # n-max = database #n-max

3 VMs

MongoDB VM #4 MongoDB VM #5 MongoDB VM #6

MongoDB Cluster #2

Service Instance #n+2

Service Instance #n+3

Service Instance #…

Service Instance # 2*n-max

Page 204: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Placement Problem

Page 205: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Placement Problem

3 VMs

MongoDB VM #2 MongoDB VM #3

MongoDB Cluster #1

Service Instance #1 = database #1

Service Instance #3 = database #3

Service Instance #5 = database #5

Service Instance #… = database #…

Service Instance # n-max = database #n-max

3 VMs

MongoDB VM #4 MongoDB VM #5 MongoDB VM #6

MongoDB Cluster #2

Service Instance #n+2

Service Instance #n+3

Service Instance #…

Service Instance # 2*n-max

Page 206: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Placement Problem

3 VMs

MongoDB VM #2 MongoDB VM #3

MongoDB Cluster #1

Service Instance #1 = database #1

Service Instance #3 = database #3

Service Instance #5 = database #5

Service Instance #… = database #…

Service Instance # n-max = database #n-max

3 VMs

MongoDB VM #4 MongoDB VM #5 MongoDB VM #6

MongoDB Cluster #2

Service Instance #n+2

Service Instance #n+3

Service Instance #…

Service Instance # 2*n-max

New Service Instance?

Page 207: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Strategy to place new service instances is required

and may require data service specific logic.

Placement Problem

3 VMs

MongoDB VM #2 MongoDB VM #3

MongoDB Cluster #1

Service Instance #1 = database #1

Service Instance #3 = database #3

Service Instance #5 = database #5

Service Instance #… = database #…

Service Instance # n-max = database #n-max

3 VMs

MongoDB VM #4 MongoDB VM #5 MongoDB VM #6

MongoDB Cluster #2

Service Instance #n+2

Service Instance #n+3

Service Instance #…

Service Instance # 2*n-max

New Service Instance

Page 208: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cluster Rebalancing

Page 209: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cluster Rebalancing

3 VMs

MongoDB VM #2 MongoDB VM #3

MongoDB Cluster #1

Service Instance #1 = database #1

Service Instance #3 = database #3

Service Instance #5 = database #5

Service Instance #… = database #…

Service Instance # n-max = database #n-max

3 VMs

MongoDB VM #4 MongoDB VM #5 MongoDB VM #6

MongoDB Cluster #2

Service Instance #n+2

Service Instance #n+3

Service Instance #…

Service Instance # 2*n-max

Page 210: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cluster Rebalancing

3 VMs

MongoDB VM #2 MongoDB VM #3

MongoDB Cluster #1

Service Instance #1 = database #1

Service Instance #3 = database #3

Service Instance #5 = database #5

Service Instance #… = database #…

Service Instance # n-max = database #n-max

3 VMs

MongoDB VM #4 MongoDB VM #5 MongoDB VM #6

MongoDB Cluster #2

Service Instance #n+2

Service Instance # 2*n-max

Page 211: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

A unbalanced set of clusters wastes

infrastructure resources.

Cluster Rebalancing

3 VMs

MongoDB VM #2 MongoDB VM #3

MongoDB Cluster #1

Service Instance #1 = database #1

Service Instance #3 = database #3

Service Instance #5 = database #5

Service Instance #… = database #…

Service Instance # n-max = database #n-max

3 VMs

MongoDB VM #4 MongoDB VM #5 MongoDB VM #6

MongoDB Cluster #2

Service Instance #n+2

Service Instance # 2*n-max

Page 212: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cluster Rebalancing

3 VMs

MongoDB VM #2 MongoDB VM #3

MongoDB Cluster #1

Service Instance #1 = database #1

Service Instance #3 = database #3

Service Instance #5 = database #5

Service Instance #… = database #…

Service Instance # n-max = database #n-max

3 VMs

MongoDB VM #4 MongoDB VM #5 MongoDB VM #6

MongoDB Cluster #2

Service Instance #n+2

Service Instance # 2*n-max

Page 213: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

A cluster rebalance freeing infrastructure

resources would desirable.

Cluster Rebalancing

3 VMs

MongoDB VM #2 MongoDB VM #3

MongoDB Cluster #1

Service Instance #1 = database #1

Service Instance #3 = database #3

Service Instance #5 = database #5

Service Instance #… = database #…

Service Instance # n-max = database #n-max

Service Instance #n+2

Service Instance # 2*n-max

Page 214: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Shared Cluster Conclusion

Page 215: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

• Scalability issued can be addressed

• Isolation issues are heavily data-service

specific > A generic solution is not

possible.

Page 216: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Scaling Dedicated Containers

Page 217: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Better Isolation

Page 218: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

2 VMs across 2 AZs

PosgreSQL Cell

Docker host VM #1 Docker host VM #2

Scaling Dedicated Containers

Page 219: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

2 VMs across 2 AZs

PosgreSQL Cell

Docker host VM #1 Docker host VM #2

Scaling Dedicated Containers

Service Instance #1 = 2 Docker containers

+ 2 PostgreSQL processes

+ 2 PostgreSQL databases asynchronously replicated

Page 220: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

2 VMs across 2 AZs

PosgreSQL Cell

Docker host VM #1 Docker host VM #2

Scaling Dedicated Containers

Service Instance #1 = 2 Docker containers

+ 2 PostgreSQL processes

+ 2 PostgreSQL databases asynchronously replicated

Service Instance #2 = 2 Docker containers

+ 2 PostgreSQL processes

+ 2 PostgreSQL databases asynchronously replicated

Page 221: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

How to scale?

Page 222: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

2 VMs across 2 AZs

PosgreSQL Cell

Docker host VM #1 Docker host VM #2

Scaling Dedicated Containers

Service Instance #1 = 2 Docker containers

+ 2 PostgreSQL processes

+ 2 PostgreSQL databases asynchronously replicated

Service Instance #2 = 2 Docker containers

+ 2 PostgreSQL processes

+ 2 PostgreSQL databases asynchronously replicated

Page 223: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

2 VMs across 2 AZs

PosgreSQL Cell

Docker host VM #1 Docker host VM #2

Scaling Dedicated Containers

Service Instance #1 = 2 Docker containers

+ 2 PostgreSQL processes

+ 2 PostgreSQL databases asynchronously replicated

Service Instance #2 = 2 Docker containers

+ 2 PostgreSQL processes

+ 2 PostgreSQL databases asynchronously replicated

Page 224: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Structural Limitation!

Page 225: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

What to do when the Cell/Cluster is full?

Scaling a shared VM cluster

Page 226: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Scaling Dedicated Containers

2 VMs across 2 AZs

PosgreSQL Cell #1

Docker host VM #1 Docker host VM #2

Service Instance #1 = 2 Docker containers

+ 2 PostgreSQL processes

Service Instance #2 = 2 Docker containers

+ 2 PostgreSQL processes

2 VMs across 2 AZs

PosgreSQL Cell #2

Docker host VM #3 Docker host VM #4

Service Instance #3 = 2 Docker containers

+ 2 PostgreSQL processes

Service Instance #3 = 2 Docker containers

+ 2 PostgreSQL processes

Page 227: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Same Service Broker Challenge

Page 228: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

New Challenge: How to add Cell-VMs on-demand?

Page 229: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

On-Demand VM provisioning is unavoidable.

Page 230: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Why not delegate most challenges?

Page 231: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

On-Demand Dedicated VMs and Clusters

Page 232: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Architecture

Page 233: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

a9s Deployer

Templates Deployments

Bosh

a9s Service Broker

my-3node-mongodb-cluster-2

MongoDB

VM#1

MongoDB

VM#2

MongoDB

VM#3

my-single-mongodb-1

MongoDB

VM#1

Middleware Adapter

Cloud Foundry Adapter

a9s MongoDB SPI

Service InstanceService Instance

my-3node-mongodb-cluster-3

MongoDB

VM#1

MongoDB

VM#2

MongoDB

VM#3

Service Instance

Cloud ControllerCF Clientcreate service

create service

create deployment from template xy with attributes {…}

deploy release abc & deployment manifest xyz

Execute deployments

create

service specific credentials

create binding

Page 234: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Let BOSH do the VM orchestration!

Page 235: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Let the infrastructure solve the placement and fragmentation challenge!

Page 236: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Shared Data Services

Page 237: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

• Single VM or single

cluster of VMs

• Single PostgreSQL

server or single

PostgreSQL cluster

• Isolation limited to

PostreSQL multi-

tenancy capabilities

Shared PostgreSQL Cluster > Bad idea

3 VMs

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3

1 VM

Postgresql

VM#1

PostgreSQL Cluster

Single PostgreSQL Server

Service Instance

Service Instance 2

Service Instance 3

Service Instance 1

Service Instance 2

Service Instance 3

Service Instance 1

Service Instance 2

Service Instance 3

Service Instance 1

Service Instance 2

Service Instance 3

Service Instance 1

OR

1x

1x

Page 238: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Shared PostgreSQL = SPOF

Page 239: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cloud Foundry Runtime

3 VMs

PostgreSQL Cluster

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

Page 240: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cloud Foundry Runtime

3 VMs

PostgreSQL Cluster

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

App App App App

App App App App

App App App App App

App App App App App App

App App

App App

App App

App App App

App

App App App App App App App

App App App App App App

App App App App App App

App App App App App

App App App App

App App App App App App App App

App App App App App App App App

App App App App App App App App

App App App App App App App

App App App App App App App App App

App App App

Service Instance

Service Instance

Service Instance

Page 241: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cloud Foundry Runtime

3 VMs

PostgreSQL Cluster

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

App App App App

App App App App

App App App App App

App App App App App App

App App

App App

App App

App App App

App

App App App App App App App

Service Instance

Service Instance

Service Instance

Page 242: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cloud Foundry Runtime

3 VMs

PostgreSQL Cluster

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

App App App App

App App App App

App App App App App

App App App App App App

App App

App App

App App

App App App

App

App App App App App App App

Service Instance

Service Instance

Service Instance

Page 243: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Your shared PostgreSQL cluster goes down, all your PostgreSQL database instances go down.

Page 244: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Beware of bad neighborhood

Page 245: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cloud Foundry Runtime

3 VMs

PostgreSQL Cluster

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

Page 246: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cloud Foundry Runtime

3 VMs

PostgreSQL Cluster

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

👹

👹 👹

👹

👹 👹

👹 👹

Page 247: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cloud Foundry Runtime

3 VMs

PostgreSQL Cluster

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

👹

👹 👹

👹

👹 👹

👹 👹

Page 248: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cloud Foundry Runtime

3 VMs

PostgreSQL Cluster

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

Service Instance ⚠

👹

👹 👹

👹

👹 👹

👹 👹

Page 249: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cloud Foundry Runtime

3 VMs

PostgreSQL Cluster

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

Service Instance ⚠

Service Instance ⚠

Service Instance ⚠ Service Instance ⚠

Service Instance ⚠

Service Instance ⚠ Service Instance ⚠

Service Instance ⚠

Service Instance ⚠

👹

👹 👹

👹

👹 👹

👹 👹

Page 250: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Shared clusters are vulnerable to bad neighbors

Page 251: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Dedicated

Page 252: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

• Service instance =

dedicated VM or

dedicated cluster of

VMs

• Uses infrastructure

isolation to enable

multi-tenancy support

Dedicated PostgreSQL instances > Good idea

my-3node-postgres-cluster-2

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3

my-single-postgres-1

Postgresql

VM#1

Service Instance

Service Instance

n x

m x

and / or

Page 253: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cloud Foundry Runtime

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

Postgresql VM#1

Postgresql VM#2

Postgresql VM#3

Service Instance

Postgresql VM

Service Instance

Postgresql VM

Service Instance

Postgresql VM

Service Instance

Postgresql VM

Service Instance

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3

Service Instance

Postgresql VM

Service Instance

Postgresql VM

Service Instance

Page 254: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cloud Foundry Runtime

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

Postgresql VM#1

Postgresql VM#2

Postgresql VM#3

Service Instance

Postgresql VM

Service Instance

Postgresql VM

Service Instance

Postgresql VM

Service Instance

Postgresql VM

Service Instance

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3

Service Instance

Postgresql VM

Service Instance

Postgresql VM

Service Instance

Page 255: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cloud Foundry Runtime

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

Postgresql VM#1

Postgresql VM#2

Postgresql VM#3

Service Instance

Postgresql VM

Service Instance

Postgresql VM

Service Instance

Postgresql VM

Service Instance

Postgresql VM

Service Instance

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3

Service Instance

Postgresql VM

Service Instance

Postgresql VM

Service Instance

Page 256: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

PostgreSQL failures are contained. Only one service instance affected.

Page 257: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Bad neighborhood protection with dedicated service instances

Page 258: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cloud Foundry Runtime

3 VMs

PostgreSQL Cluster = Service Instance #2

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance Service Instance Service Instance

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

3 VMs

PostgreSQL Cluster = Service Instance #1

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance Service Instance Service Instance

3 VMs

PostgreSQL Cluster = Service Instance #3

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance Service Instance Service Instance

Page 259: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cloud Foundry Runtime

3 VMs

PostgreSQL Cluster = Service Instance #2

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance Service Instance Service Instance

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

👹

👹 👹

👹

👹 👹

👹 👹

3 VMs

PostgreSQL Cluster = Service Instance #1

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance Service Instance Service Instance

3 VMs

PostgreSQL Cluster = Service Instance #3

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance Service Instance Service Instance

Page 260: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cloud Foundry Runtime

3 VMs

PostgreSQL Cluster = Service Instance #2

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance Service Instance Service Instance

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

👹

👹 👹

👹

👹 👹

👹 👹

3 VMs

PostgreSQL Cluster = Service Instance #1

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance Service Instance Service Instance

3 VMs

PostgreSQL Cluster = Service Instance #3

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance Service Instance Service Instance

Page 261: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cloud Foundry Runtime

3 VMs

PostgreSQL Cluster = Service Instance #2

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance Service Instance Service Instance

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

Service Instance ⚠ Service Instance ⚠ Service Instance ⚠

👹

👹 👹

👹

👹 👹

👹 👹

3 VMs

PostgreSQL Cluster = Service Instance #1

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance Service Instance Service Instance

3 VMs

PostgreSQL Cluster = Service Instance #3

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance Service Instance Service Instance

Page 262: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cloud Foundry Runtime

3 VMs

PostgreSQL Cluster = Service Instance #2

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance Service Instance Service Instance

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

Service Instance ⚠ Service Instance ⚠ Service Instance ⚠

👹

👹 👹

👹

👹 👹

👹 👹

3 VMs

PostgreSQL Cluster = Service Instance #1

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance Service Instance Service Instance

3 VMs

PostgreSQL Cluster = Service Instance #3

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance Service Instance Service Instance

Page 263: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cloud Foundry Runtime

3 VMs

PostgreSQL Cluster = Service Instance #2

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance Service Instance Service Instance

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

Service Instance ⚠ Service Instance ⚠ Service Instance ⚠

👹

👹 👹

👹

👹 👹

👹 👹

3 VMs

PostgreSQL Cluster = Service Instance #1

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance Service Instance Service Instance

3 VMs

PostgreSQL Cluster = Service Instance #3

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance Service Instance Service Instance

Page 264: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cloud Foundry Runtime

3 VMs

PostgreSQL Cluster = Service Instance #2

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance Service Instance Service Instance

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

Service Instance ⚠ Service Instance ⚠ Service Instance ⚠

👹

👹 👹

👹

👹 👹

👹 👹

3 VMs

PostgreSQL Cluster = Service Instance #1

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance Service Instance Service Instance

3 VMs

PostgreSQL Cluster = Service Instance #3

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance Service Instance Service Instance

Infrastructure isolation

Page 265: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Dedicated clusters isolate bad neighbors

Page 266: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cloud

Page 267: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cloud

Automation

Page 268: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cloud

Automation

Robustness

Page 269: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cloud

Automation

Self-Healing

Robustness

Page 270: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cloud

Automation

Self-Healing

Scalability

Robustness

Page 271: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cloud

Automation

Self-Healing

Scalability

On-demand self-service

Robustness

Page 272: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

VM vs. Container

Resource TypePre-provisioned

vs. On-demand-provisioning

Provisioning

Single replica vs.

Data redundancy / Multiple replicas

Resurrection Failover vs.

Standby-Failover

Failover Strategy

Data Redundancy

Automation Technology

BOSH vs. Chef vs. Puppet

Service InstancesShared Dedicated

Infrastructure Reliability

Perfect. HA VMs. No SPOFs. Never fails. VMs cost more than a

Design to fail. Fails from time to time.

Saves money.

Page 273: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Seconds, minutes, hours?

Desired time to repair Service instance availability

Service broker availability

Availability

Service broker performance (ops/s) Service instance performance

Time to provision service instance.

PerformanceAccessibilityRemote log-in to service instances.

ConfigurabilityAdapt to local network

and security policies. Integrate existing

infrastructure.

SecurityNetwork security.

Encryption.

TransparencyAccessing metrics and logs.

OperabilityEasyness to operate and

maintain.

Page 274: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

1. Define a service instance! 2. Define total # service instances! 3. Define # service instance CRUD ops / min!

Page 275: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Common Data Service

Design Patterns

Page 276: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

A. Shared VM cluster

B. Dedicated containers

C. Dedicated VMs / VM clusters

Common Data Service Design Patterns

Page 277: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Scaling a shared VM cluster

Page 278: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

3 VMs

MongoDB Cluster

MongoDB VM #1 MongoDB VM #2 MongoDB VM #3

Scaling a shared VM cluster

Page 279: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

3 VMs

MongoDB Cluster

MongoDB VM #1 MongoDB VM #2 MongoDB VM #3

Scaling a shared VM cluster

Page 280: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

3 VMs

MongoDB Cluster

MongoDB VM #1 MongoDB VM #2 MongoDB VM #3

Service Instance #1 = database #1

Service Instance #2 = database #2

Service Instance #3 = database #3

Service Instance #4 = database #4

Service Instance #5 = database #5

Service Instance #6 = database #6

Service Instance #… = database #…

Service Instance # n-max = database #n-max

Scaling a shared VM cluster

Page 281: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

3 VMs

MongoDB Cluster

MongoDB VM #1 MongoDB VM #2 MongoDB VM #3

Service Instance #1 = database #1

Service Instance #2 = database #2

Service Instance #3 = database #3

Service Instance #4 = database #4

Service Instance #5 = database #5

Service Instance #6 = database #6

Service Instance #… = database #…

Service Instance # n-max = database #n-max

Scaling a shared VM cluster

Page 282: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Low costs per service instance

Scaling a shared VM cluster

Page 283: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Simple Service Broker Logic

Scaling a shared VM cluster

Page 284: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

create service → create a database

Page 285: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

create service binding → create a database user

Page 286: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Weak Isolation!

Page 287: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Structural Limitation!

Page 288: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

What to do when the shared cluster is full?

Scaling a shared VM cluster

Page 289: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

MongoDB VM #1 MongoDB VM #2 MongoDB VM #3

Service Instance #1 = database #1

Service Instance #2 = database #2

Service Instance #3 = database #3

Service Instance #4 = database #4

Service Instance #5 = database #5

Service Instance #6 = database #6

Service Instance #… = database #…

Service Instance # n-max = database #n-max

Scaling a shared VM cluster

3 VMs

MongoDB Cluster

Service Instance #1 = database #1

Service Instance #2 = database #2

Service Instance #3 = database #3

Service Instance #4 = database #4

Service Instance #5 = database #5

Service Instance #6 = database #6

Service Instance #… = database #…

Service Instance # n-max = database #n-max

Page 290: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

3 VMs

MongoDB VM #1 MongoDB VM #2 MongoDB VM #3

MongoDB Cluster #1

Service Instance #1 = database #1

Service Instance #2 = database #2

Service Instance #3 = database #3

Service Instance #4 = database #4

Service Instance #5 = database #5

Service Instance #6 = database #6

Service Instance #… = database #…

Service Instance # n-max = database #n-max

Scaling a shared VM cluster

3 VMs

MongoDB Cluster

Service Instance #1 = database #1

Service Instance #2 = database #2

Service Instance #3 = database #3

Service Instance #4 = database #4

Service Instance #5 = database #5

Service Instance #6 = database #6

Service Instance #… = database #…

Service Instance # n-max = database #n-max

Page 291: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

3 VMs

MongoDB VM #1 MongoDB VM #2 MongoDB VM #3

MongoDB Cluster #1

Service Instance #1 = database #1

Service Instance #2 = database #2

Service Instance #3 = database #3

Service Instance #4 = database #4

Service Instance #5 = database #5

Service Instance #6 = database #6

Service Instance #… = database #…

Service Instance # n-max = database #n-max

Scaling a shared VM cluster

Page 292: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

3 VMs

MongoDB VM #1 MongoDB VM #2 MongoDB VM #3

MongoDB Cluster #1

Service Instance #1 = database #1

Service Instance #2 = database #2

Service Instance #3 = database #3

Service Instance #4 = database #4

Service Instance #5 = database #5

Service Instance #6 = database #6

Service Instance #… = database #…

Service Instance # n-max = database #n-max

Scaling a shared VM cluster

3 VMs

MongoDB VM #4 MongoDB VM #5 MongoDB VM #6

MongoDB Cluster #2

Service Instance #n+1

Service Instance #n+2

Service Instance #n+3

Service Instance #n+4

Service Instance #n+5

Service Instance #n+6

Service Instance #…

Service Instance # 2*n-max

Page 293: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Service Broker Logic

Scaling a shared VM cluster

Simple

Page 294: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Service Broker Logic

Scaling a shared VM cluster

Complex

Page 295: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Fragmentation

Page 296: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Caused by frequent creation and / deletion of

service instances

Fragmentation

3 VMs

MongoDB VM #2 MongoDB VM #3

MongoDB Cluster #1

Service Instance #1 = database #1

Service Instance #2 = database #2

Service Instance #3 = database #3

Service Instance #4 = database #4

Service Instance #5 = database #5

Service Instance #6 = database #6

Service Instance #… = database #…

Service Instance # n-max = database #n-max

3 VMs

MongoDB VM #4 MongoDB VM #5 MongoDB VM #6

MongoDB Cluster #2

Service Instance #n+1

Service Instance #n+2

Service Instance #n+3

Service Instance #n+4

Service Instance #n+5

Service Instance #n+6

Service Instance #…

Service Instance # 2*n-max

Page 297: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Caused by frequent creation and / deletion of

service instances

Fragmentation

3 VMs

MongoDB VM #2 MongoDB VM #3

MongoDB Cluster #1

Service Instance #1 = database #1

Service Instance #3 = database #3

Service Instance #5 = database #5

Service Instance #… = database #…

Service Instance # n-max = database #n-max

3 VMs

MongoDB VM #4 MongoDB VM #5 MongoDB VM #6

MongoDB Cluster #2

Service Instance #n+2

Service Instance #n+3

Service Instance #…

Service Instance # 2*n-max

Page 298: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Placement Problem

Page 299: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Placement Problem

3 VMs

MongoDB VM #2 MongoDB VM #3

MongoDB Cluster #1

Service Instance #1 = database #1

Service Instance #3 = database #3

Service Instance #5 = database #5

Service Instance #… = database #…

Service Instance # n-max = database #n-max

3 VMs

MongoDB VM #4 MongoDB VM #5 MongoDB VM #6

MongoDB Cluster #2

Service Instance #n+2

Service Instance #n+3

Service Instance #…

Service Instance # 2*n-max

Page 300: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Placement Problem

3 VMs

MongoDB VM #2 MongoDB VM #3

MongoDB Cluster #1

Service Instance #1 = database #1

Service Instance #3 = database #3

Service Instance #5 = database #5

Service Instance #… = database #…

Service Instance # n-max = database #n-max

3 VMs

MongoDB VM #4 MongoDB VM #5 MongoDB VM #6

MongoDB Cluster #2

Service Instance #n+2

Service Instance #n+3

Service Instance #…

Service Instance # 2*n-max

New Service Instance?

Page 301: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Strategy to place new service instances is required

and may require data service specific logic.

Placement Problem

3 VMs

MongoDB VM #2 MongoDB VM #3

MongoDB Cluster #1

Service Instance #1 = database #1

Service Instance #3 = database #3

Service Instance #5 = database #5

Service Instance #… = database #…

Service Instance # n-max = database #n-max

3 VMs

MongoDB VM #4 MongoDB VM #5 MongoDB VM #6

MongoDB Cluster #2

Service Instance #n+2

Service Instance #n+3

Service Instance #…

Service Instance # 2*n-max

New Service Instance

Page 302: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cluster Rebalancing

Page 303: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cluster Rebalancing

3 VMs

MongoDB VM #2 MongoDB VM #3

MongoDB Cluster #1

Service Instance #1 = database #1

Service Instance #3 = database #3

Service Instance #5 = database #5

Service Instance #… = database #…

Service Instance # n-max = database #n-max

3 VMs

MongoDB VM #4 MongoDB VM #5 MongoDB VM #6

MongoDB Cluster #2

Service Instance #n+2

Service Instance #n+3

Service Instance #…

Service Instance # 2*n-max

Page 304: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cluster Rebalancing

3 VMs

MongoDB VM #2 MongoDB VM #3

MongoDB Cluster #1

Service Instance #1 = database #1

Service Instance #3 = database #3

Service Instance #5 = database #5

Service Instance #… = database #…

Service Instance # n-max = database #n-max

3 VMs

MongoDB VM #4 MongoDB VM #5 MongoDB VM #6

MongoDB Cluster #2

Service Instance #n+2

Service Instance # 2*n-max

Page 305: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

A unbalanced set of clusters wastes

infrastructure resources.

Cluster Rebalancing

3 VMs

MongoDB VM #2 MongoDB VM #3

MongoDB Cluster #1

Service Instance #1 = database #1

Service Instance #3 = database #3

Service Instance #5 = database #5

Service Instance #… = database #…

Service Instance # n-max = database #n-max

3 VMs

MongoDB VM #4 MongoDB VM #5 MongoDB VM #6

MongoDB Cluster #2

Service Instance #n+2

Service Instance # 2*n-max

Page 306: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cluster Rebalancing

3 VMs

MongoDB VM #2 MongoDB VM #3

MongoDB Cluster #1

Service Instance #1 = database #1

Service Instance #3 = database #3

Service Instance #5 = database #5

Service Instance #… = database #…

Service Instance # n-max = database #n-max

3 VMs

MongoDB VM #4 MongoDB VM #5 MongoDB VM #6

MongoDB Cluster #2

Service Instance #n+2

Service Instance # 2*n-max

Page 307: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

A cluster rebalance freeing infrastructure

resources would desirable.

Cluster Rebalancing

3 VMs

MongoDB VM #2 MongoDB VM #3

MongoDB Cluster #1

Service Instance #1 = database #1

Service Instance #3 = database #3

Service Instance #5 = database #5

Service Instance #… = database #…

Service Instance # n-max = database #n-max

Service Instance #n+2

Service Instance # 2*n-max

Page 308: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Shared Cluster Conclusion

Page 309: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

• Scalability issued can be addressed

• Isolation issues are heavily data-service

specific > A generic solution is not

possible.

Page 310: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Scaling Dedicated Containers

Page 311: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Better Isolation

Page 312: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

2 VMs across 2 AZs

PosgreSQL Cell

Docker host VM #1 Docker host VM #2

Scaling Dedicated Containers

Page 313: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

2 VMs across 2 AZs

PosgreSQL Cell

Docker host VM #1 Docker host VM #2

Scaling Dedicated Containers

Service Instance #1 = 2 Docker containers

+ 2 PostgreSQL processes

+ 2 PostgreSQL databases asynchronously replicated

Page 314: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

2 VMs across 2 AZs

PosgreSQL Cell

Docker host VM #1 Docker host VM #2

Scaling Dedicated Containers

Service Instance #1 = 2 Docker containers

+ 2 PostgreSQL processes

+ 2 PostgreSQL databases asynchronously replicated

Service Instance #2 = 2 Docker containers

+ 2 PostgreSQL processes

+ 2 PostgreSQL databases asynchronously replicated

Page 315: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

How to scale?

Page 316: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

2 VMs across 2 AZs

PosgreSQL Cell

Docker host VM #1 Docker host VM #2

Scaling Dedicated Containers

Service Instance #1 = 2 Docker containers

+ 2 PostgreSQL processes

+ 2 PostgreSQL databases asynchronously replicated

Service Instance #2 = 2 Docker containers

+ 2 PostgreSQL processes

+ 2 PostgreSQL databases asynchronously replicated

Page 317: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

2 VMs across 2 AZs

PosgreSQL Cell

Docker host VM #1 Docker host VM #2

Scaling Dedicated Containers

Service Instance #1 = 2 Docker containers

+ 2 PostgreSQL processes

+ 2 PostgreSQL databases asynchronously replicated

Service Instance #2 = 2 Docker containers

+ 2 PostgreSQL processes

+ 2 PostgreSQL databases asynchronously replicated

Page 318: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Structural Limitation!

Page 319: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

What to do when the Cell/Cluster is full?

Scaling a shared VM cluster

Page 320: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Scaling Dedicated Containers

2 VMs across 2 AZs

PosgreSQL Cell #1

Docker host VM #1 Docker host VM #2

Service Instance #1 = 2 Docker containers

+ 2 PostgreSQL processes

Service Instance #2 = 2 Docker containers

+ 2 PostgreSQL processes

2 VMs across 2 AZs

PosgreSQL Cell #2

Docker host VM #3 Docker host VM #4

Service Instance #3 = 2 Docker containers

+ 2 PostgreSQL processes

Service Instance #3 = 2 Docker containers

+ 2 PostgreSQL processes

Page 321: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Same Service Broker Challenge

Page 322: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

New Challenge: How to add Cell-VMs on-demand?

Page 323: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

On-Demand VM provisioning is unavoidable.

Page 324: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Why not delegate most challenges?

Page 325: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

On-Demand Dedicated VMs and Clusters

Page 326: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Architecture

Page 327: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

a9s Deployer

Templates Deployments

Bosh

a9s Service Broker

my-3node-mongodb-cluster-2

MongoDB

VM#1

MongoDB

VM#2

MongoDB

VM#3

my-single-mongodb-1

MongoDB

VM#1

Middleware Adapter

Cloud Foundry Adapter

a9s MongoDB SPI

Service InstanceService Instance

my-3node-mongodb-cluster-3

MongoDB

VM#1

MongoDB

VM#2

MongoDB

VM#3

Service Instance

Cloud ControllerCF Clientcreate service

create service

create deployment from template xy with attributes {…}

deploy release abc & deployment manifest xyz

Execute deployments

create

service specific credentials

create binding

Page 328: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Let BOSH do the VM orchestration!

Page 329: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Let the infrastructure solve the placement and fragmentation challenge!

Page 330: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Shared Services Instances

Page 331: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

• Single VM or single

cluster of VMs

• Single PostgreSQL

server or single

PostgreSQL cluster

• Isolation limited to

PostreSQL multi-

tenancy capabilities

Shared PostgreSQL Cluster > Bad idea

3 VMs

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3

1 VM

Postgresql

VM#1

PostgreSQL Cluster

Single PostgreSQL Server

Service Instance

Service Instance 2

Service Instance 3

Service Instance 1

Service Instance 2

Service Instance 3

Service Instance 1

Service Instance 2

Service Instance 3

Service Instance 1

Service Instance 2

Service Instance 3

Service Instance 1

OR

1x

1x

Page 332: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Shared PostgreSQL = SPOF

Page 333: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cloud Foundry Runtime

3 VMs

PostgreSQL Cluster

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

Page 334: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cloud Foundry Runtime

3 VMs

PostgreSQL Cluster

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

App App App App

App App App App

App App App App App

App App App App App App

App App

App App

App App

App App App

App

App App App App App App App

App App App App App App

App App App App App App

App App App App App

App App App App

App App App App App App App App

App App App App App App App App

App App App App App App App App

App App App App App App App

App App App App App App App App App

App App App

Service Instance

Service Instance

Service Instance

Page 335: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cloud Foundry Runtime

3 VMs

PostgreSQL Cluster

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

App App App App

App App App App

App App App App App

App App App App App App

App App

App App

App App

App App App

App

App App App App App App App

Service Instance

Service Instance

Service Instance

Page 336: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cloud Foundry Runtime

3 VMs

PostgreSQL Cluster

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

App App App App

App App App App

App App App App App

App App App App App App

App App

App App

App App

App App App

App

App App App App App App App

Service Instance

Service Instance

Service Instance

Page 337: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Your shared PostgreSQL cluster goes down, all your PostgreSQL database instances go down.

Page 338: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Beware of bad neighborhood

Page 339: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cloud Foundry Runtime

3 VMs

PostgreSQL Cluster

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

Page 340: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cloud Foundry Runtime

3 VMs

PostgreSQL Cluster

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

👹

👹 👹

👹

👹 👹

👹 👹

Page 341: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cloud Foundry Runtime

3 VMs

PostgreSQL Cluster

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

👹

👹 👹

👹

👹 👹

👹 👹

Page 342: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cloud Foundry Runtime

3 VMs

PostgreSQL Cluster

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

Service Instance ⚠

👹

👹 👹

👹

👹 👹

👹 👹

Page 343: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cloud Foundry Runtime

3 VMs

PostgreSQL Cluster

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

Service Instance

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

Service Instance ⚠

Service Instance ⚠

Service Instance ⚠ Service Instance ⚠

Service Instance ⚠

Service Instance ⚠ Service Instance ⚠

Service Instance ⚠

Service Instance ⚠

👹

👹 👹

👹

👹 👹

👹 👹

Page 344: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Shared clusters are vulnerable to bad neighbors

Page 345: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Dedicated Service Instances

Page 346: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

• Service instance =

dedicated VM or

dedicated cluster of

VMs

• Uses infrastructure

isolation to enable

multi-tenancy support

Dedicated PostgreSQL instances > Good idea

my-3node-postgres-cluster-2

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3

my-single-postgres-1

Postgresql

VM#1

Service Instance

Service Instance

n x

m x

and / or

Page 347: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cloud Foundry Runtime

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

Postgresql VM#1

Postgresql VM#2

Postgresql VM#3

Service Instance

Postgresql VM

Service Instance

Postgresql VM

Service Instance

Postgresql VM

Service Instance

Postgresql VM

Service Instance

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3

Service Instance

Postgresql VM

Service Instance

Postgresql VM

Service Instance

Page 348: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cloud Foundry Runtime

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

Postgresql VM#1

Postgresql VM#2

Postgresql VM#3

Service Instance

Postgresql VM

Service Instance

Postgresql VM

Service Instance

Postgresql VM

Service Instance

Postgresql VM

Service Instance

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3

Service Instance

Postgresql VM

Service Instance

Postgresql VM

Service Instance

Page 349: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cloud Foundry Runtime

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

Postgresql VM#1

Postgresql VM#2

Postgresql VM#3

Service Instance

Postgresql VM

Service Instance

Postgresql VM

Service Instance

Postgresql VM

Service Instance

Postgresql VM

Service Instance

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3

Service Instance

Postgresql VM

Service Instance

Postgresql VM

Service Instance

Page 350: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

PostgreSQL failures are contained. Only one service instance affected.

Page 351: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Bad neighborhood protection with dedicated service instances

Page 352: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cloud Foundry Runtime

3 VMs

PostgreSQL Cluster = Service Instance #2

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance Service Instance Service Instance

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

3 VMs

PostgreSQL Cluster = Service Instance #1

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance Service Instance Service Instance

3 VMs

PostgreSQL Cluster = Service Instance #3

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance Service Instance Service Instance

Page 353: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cloud Foundry Runtime

3 VMs

PostgreSQL Cluster = Service Instance #2

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance Service Instance Service Instance

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

👹

👹 👹

👹

👹 👹

👹 👹

3 VMs

PostgreSQL Cluster = Service Instance #1

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance Service Instance Service Instance

3 VMs

PostgreSQL Cluster = Service Instance #3

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance Service Instance Service Instance

Page 354: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cloud Foundry Runtime

3 VMs

PostgreSQL Cluster = Service Instance #2

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance Service Instance Service Instance

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

👹

👹 👹

👹

👹 👹

👹 👹

3 VMs

PostgreSQL Cluster = Service Instance #1

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance Service Instance Service Instance

3 VMs

PostgreSQL Cluster = Service Instance #3

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance Service Instance Service Instance

Page 355: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cloud Foundry Runtime

3 VMs

PostgreSQL Cluster = Service Instance #2

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance Service Instance Service Instance

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

Service Instance ⚠ Service Instance ⚠ Service Instance ⚠

👹

👹 👹

👹

👹 👹

👹 👹

3 VMs

PostgreSQL Cluster = Service Instance #1

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance Service Instance Service Instance

3 VMs

PostgreSQL Cluster = Service Instance #3

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance Service Instance Service Instance

Page 356: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cloud Foundry Runtime

3 VMs

PostgreSQL Cluster = Service Instance #2

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance Service Instance Service Instance

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

Service Instance ⚠ Service Instance ⚠ Service Instance ⚠

👹

👹 👹

👹

👹 👹

👹 👹

3 VMs

PostgreSQL Cluster = Service Instance #1

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance Service Instance Service Instance

3 VMs

PostgreSQL Cluster = Service Instance #3

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance Service Instance Service Instance

Page 357: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cloud Foundry Runtime

3 VMs

PostgreSQL Cluster = Service Instance #2

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance Service Instance Service Instance

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

Service Instance ⚠ Service Instance ⚠ Service Instance ⚠

👹

👹 👹

👹

👹 👹

👹 👹

3 VMs

PostgreSQL Cluster = Service Instance #1

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance Service Instance Service Instance

3 VMs

PostgreSQL Cluster = Service Instance #3

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance Service Instance Service Instance

Page 358: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Cloud Foundry Runtime

3 VMs

PostgreSQL Cluster = Service Instance #2

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance Service Instance Service Instance

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

App App App App App App App App App App

Service Instance ⚠ Service Instance ⚠ Service Instance ⚠

👹

👹 👹

👹

👹 👹

👹 👹

3 VMs

PostgreSQL Cluster = Service Instance #1

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance Service Instance Service Instance

3 VMs

PostgreSQL Cluster = Service Instance #3

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3Service Instance Service Instance Service Instance

Infrastructure isolation

Page 359: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Dedicated clusters isolate bad neighbors

Page 360: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Pre- vs. On-Demand Provisioning

Page 361: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Pre-Provisioned

Page 362: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Pre-provisoned service instances

my-3node-postgres-cluster-2

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3

my-single-postgres-1

Postgresql

VM#1

Service InstanceService Instance

Service Broker

Page 363: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

$> cf create-service postgresql single-small my-single-postgres-1

Easy Deployment

Page 364: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Pre-provisioned service instances

my-3node-postgres-cluster-2

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3

my-single-postgres-1

Postgresql

VM#1

Service InstanceService Instance

Service Broker

Page 365: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

$> cf create-service postgresql cluster-small my-3node-postgres-

cluster-2

Easy Deployment

Page 366: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Pre-provisioned service instances

my-3node-postgres-cluster-2

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3

my-single-postgres-1

Postgresql

VM#1

Service InstanceService Instance

Service Broker

Page 367: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

On-Demand-Provisioned

Page 368: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

On-demand provisioned service instances

Service Broker

Some Automation

Page 369: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

On-demand provisioned service instances

Service Broker

Some Automation

Page 370: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

On-demand provisioned service instances

my-single-postgres-1

Postgresql

VM#1

Service Instance

Service Broker

Some Automation

Page 371: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

On-demand provisioned service instances

my-single-postgres-1

Postgresql

VM#1

Service Instance

Service Broker

Some Automation

Page 372: Beyond 1001 Dedicated Data Service Instances - … Service Instances. Introduction. The Challenge. Given: Application platform based on Cloud Foundry to serve thousands of apps. Application

Pre-provisoned service instances

my-3node-postgres-cluster-2

Postgresql

VM#1

Postgresql

VM#2

Postgresql

VM#3

my-single-postgres-1

Postgresql

VM#1

Service InstanceService Instance

Service Broker

Some Automation