SlideShare a Scribd company logo
Vertically Scaled Design
Patterns
Jeff Malnick & Paul Ambrosini
Systems Engineering @ SRC:CLR
srcclr.com | @srcclr
How this is going down:
srcclr.com | @srcclr
● History & Evolution
● Principles
● Notes & Examples
● Demo
History & Evolution
srcclr.com | @srcclr
In the beginning there was
srcclr.com | @srcclr
● AWS
● ELB
● Ansible
● SCP
● Tomcat
● We all start somewhere
Then there was
srcclr.com | @srcclr
srcclr.com | @srcclr
Paul heroically rolled it out in 2 weeks
Massive Gains
srcclr.com | @srcclr
● Huge improvement
● Split up Frontend and Backend Code
● Teams deploying separately
● Productivity went up dramatically
Wasn’t perfect
srcclr.com | @srcclr
● Not fully dynamic
● CI hooks not perfect
● Cookbook merging*
● Service health management lacking
Then we migrated...
srcclr.com | @srcclr
● *hired Jeff
○ ‘ops role’
○ or ‘devops’
We got a shiny new CM system.
srcclr.com | @srcclr
"Type" : "AWS::EC2::Instance",
"Properties" : {
"KeyName" : "secure",
"SecurityGroupIds" : ["sg-1234abcd","sg-5678efg"],
"SubnetId" : "subnet-1234abcd",
"UserData" : {
"Fn::Base64" : {
"Fn::Join" : ["", [
"#!/bin/sh -vn",
"ROLE='qa_nginx_static'n",
"MASTER='https://puppet.srcclr.com'n",
"D_ROLE=$(echo $ROLE | tr '_' '-')n",
"D_IP=$(hostname -I | tr '.' '-' | cut -d' ' -f1)n",
"HOSTNAME="$(echo $D_ROLE)-$(echo $D_IP)"n",
"echo "127.0.0.1 $HOSTNAME" >> /etc/hosts",
"apt-get updaten",
"echo $HOSTNAME > /etc/hostnamen",
"/bin/hostname $HOSTNAMEn",
"echo $ROLE > /etc/rolen",
"sudo curl -k $MASTER:8140/packages/current/install.bash | sudo bashn"
]]}
Cloud Formation for Bare Metal
Continuous Integration
srcclr.com | @srcclr
srcclr.com | @srcclr
# Executed in $WORKSPACE on jenkins
VERSION=$(some_mvn_command)
curl 
-X POST 
-d@- 
puppet.myorg.com:1015/deploy <<EOF
{
"service": "analytics",
"version": "$VERSION",
"environment": "qa",
"role": "qa_service"
}
EOF
How we do CI
New CM was better but...
srcclr.com | @srcclr
Shameless use of hooks
srcclr.com | @srcclr
include http
http::listener {‘kick_haproxy’:
port => '1234',
routes => {
'kick_haproxy' => {
'method' => 'get',
'command' => "su - peadmin -c 'mco puppet runonce -F
role == haproxy_internal'"
},
“Service Discovery”
srcclr.com | @srcclr
http { 'kick_haproxy':
ensure => get,
port => '1234',
fqdn => 'puppet.myorg.com'
}
srcclr.com | @srcclr
sc_services::service { 'librarian':
deploy_stage => 'production',
version => $version,
enable_newrelic_apm => true,
loadbalancer_role => 'production_internal',
xmx_setting => '1024',
xms_setting => '1024',
proc_opts => {
'1' => {
'env_profile' => 'prod',
'port' => '11100',
'mgmt_port' => '11110',
'override' => $properties_file,
},
'2' => {
'env_profile' => 'prod',
'port' => '11101',
'mgmt_port' => '11111',
'override' => $properties_file,
}
}
Still static...
srcclr.com | @srcclr
sc_services::service { 'librarian':
deploy_stage => 'app',
version => $version,
enable_newrelic_apm => true,
loadbalancer_role => 'production_internal',
xmx_setting => '1024',
xms_setting => '1024',
proc_opts => {
'1' => {
'env_profile' => 'app',
'port' => '11100',
'mgmt_port' => '11110',
'override' => $properties_file,
},
'2' => {
'env_profile' => 'app',
'port' => '11101',
'mgmt_port' => '11111',
'override' => $properties_file,
}
}
Still static...
{Statically
assigning ports!
srcclr.com | @srcclr
sc_services::service { 'librarian':
deploy_stage => 'app',
version => $version,
enable_newrelic_apm => true,
loadbalancer_role => 'production_internal',
xmx_setting => '1024',
xms_setting => '1024',
proc_opts => {
'1' => {
'env_profile' => 'app',
'port' => '11100',
'mgmt_port' => '11110',
'override' => $properties_file,
},
'2' => {
'env_profile' => 'app',
'port' => '11101',
'mgmt_port' => '11111',
'override' => $properties_file,
}
}
Still static...
What S3 Bucket
is this Jar from?
srcclr.com | @srcclr
sc_services::service { 'librarian':
deploy_stage => 'app',
version => $version,
enable_newrelic_apm => true,
loadbalancer_role => 'production_internal',
xmx_setting => '1024',
xms_setting => '1024',
proc_opts => {
'1' => {
'env_profile' => 'app',
'port' => '11100',
'mgmt_port' => '11110',
'override' => $properties_file,
},
'2' => {
'env_profile' => 'app',
'port' => '11101',
'mgmt_port' => '11111',
'override' => $properties_file,
}
}
Still static...
“Service Discovery”
for HaProxy
srcclr.com | @srcclr
sc_services::service { 'librarian':
deploy_stage => 'app',
version => $version,
enable_newrelic_apm => true,
loadbalancer_role => 'production_internal',
xmx_setting => '1024',
xms_setting => '1024',
proc_opts => {
'1' => {
'env_profile' => 'app',
'port' => '11100',
'mgmt_port' => '11110',
'override' => $properties_file,
},
'2' => {
'env_profile' => 'app',
'port' => '11101',
'mgmt_port' => '11111',
'override' => $properties_file,
}
}
Still static...
Service
statically
scheduled to
execute on a
node classified
by Puppet
“Scaling”
srcclr.com | @srcclr
$ports = {
'librarian' => {
'svc' => '20060-20070',
'mgmt' => '20071-20080',
},
'notifications' => {
'svc' => '20000-20010',
'mgmt' => '20011-20020',
},
'cloud_agent' => {
'svc' => '31040-31050',
'mgmt' => '31051-31060',
},
'search' => {
'svc' => '41140-41150',
'mgmt' => '41151-41160',
},
“Scaling”
srcclr.com | @srcclr
$ports = {
'librarian' => {
'svc' => '20060-20070',
'mgmt' => '20071-20080',
},
'notifications' => {
'svc' => '20000-20010',
'mgmt' => '20011-20020',
},
'cloud_agent' => {
'svc' => '31040-31050',
'mgmt' => '31051-31060',
},
'search' => {
'svc' => '41140-41150',
'mgmt' => '41151-41160',
}
...
{ Scaling to maximum of 10
instances per box.
Recap
srcclr.com | @srcclr
● CM statically schedules services to run on node
● Can scale to maximum number of known ports
● This does “scale” vertically & horizontally...
Automation Principles
A Standard Factory...
srcclr.com | @srcclr
● Bare Metal Provisioning
● Configuration Management
● Remote Execution Framework
Software Principles
The Monolith…
srcclr.com | @srcclr
As a framework it is:
srcclr.com | @srcclr
● Hard to diagnose what is broken
● One part breaks, the entire thing breaks
● Unwieldy code bases
● Works for some, wasn’t for us
The Monolith Factory
srcclr.com | @srcclr
● Statically schedules services
● Doesn’t require service discovery
The Micro-Service
srcclr.com | @srcclr
As a framework it is:
srcclr.com | @srcclr
● Atomic services
● Easy(er) to figure out what is broken
● Scale or add individual pieces
The Micro-Services Factory
srcclr.com | @srcclr
● Dynamic task scheduling
● Service discovery required
The Scaling Problem...
srcclr.com | @srcclr
● Service ‘x’ requires known port assignments
● Service ‘x’ configuration changes across env’s
● Service ‘x’ should be able to run on a box with
other instances of Service ‘x’ as well as Service ‘y’
and Service ‘z’
The Vertical Component
srcclr.com | @srcclr
● Start locally, on a single box
● Find a solution that works vertically, master it
● Once the vertical solution is found, move
horizontally
Dynamic Task Scheduling
srcclr.com | @srcclr
● Purpose built remote execution framework
What we really need...
srcclr.com | @srcclr
● Purpose built remote execution framework
● … micro services are like streakers…
They don’t care where they’re running, they just want
to be exposed.
srcclr.com | @srcclr
● Dynamic tasks scheduling
● … micro services are like streaker`
What we really need...
srcclr.com | @srcclr
● Purpose built systems
● … CM does CM; SD does SD; divide and conquer
Configuration Management
srcclr.com | @srcclr
● Is still important!
● Is still necessary!
srcclr.com | @srcclr
Our Remote Execution Framework
Our Initial Deployment
srcclr.com | @srcclr
● Apache Mesos
● Marathon
"Type" : "AWS::EC2::Instance",
"Properties" : {
"KeyName" : "secure",
"SecurityGroupIds" : ["sg-1234abcd","sg-5678efg"],
"SubnetId" : "subnet-1234abcd",
"UserData" : {
"Fn::Base64" : {
"Fn::Join" : ["", [
"#!/bin/sh -vn",
"ROLE='qa_nginx_static'n",
"MASTER='https://puppet.srcclr.com'n",
"D_ROLE=$(echo $ROLE | tr '_' '-')n",
"D_IP=$(hostname -I | tr '.' '-' | cut -d' ' -f1)n",
"HOSTNAME="$(echo $D_ROLE)-$(echo $D_IP)"n",
"echo "127.0.0.1 $HOSTNAME" >> /etc/hosts",
"apt-get updaten",
"echo $HOSTNAME > /etc/hostnamen",
"/bin/hostname $HOSTNAMEn",
"echo $ROLE > /etc/rolen",
"sudo curl -k $MASTER:8140/packages/current/install.bash | sudo bashn"
]]}
Design Pattern : Bare Metal
class roles::mesos_master {
include ::profiles::mesos::basic
include ::profiles::mesos::master
include ::profiles::docker::marathon
include ::profiles::haproxy::marathon_template
}
Design Pattern : Config Mgmt
Design Pattern : Application Layer
Mesos for Layer 7:
- Deploy application layer via Docker
- Ensure service ‘x’ is running ‘n’ number of
times
{
"container": {
"type": "DOCKER",
"docker": {
"forcePullImage": true,
"image": "malnick/microbrew",
Design Pattern : Service Discovery
Marathon for Service Discovery/Deployment:
- API to Apache Mesos
- Queried for IP/Port assignments of layer 7
resources to configure haproxy
LIVE DEMO
Are you sure you want to do this?
Pray to the demo gods
Jeff Malnick Paul Ambrosini
malnick at gmail dot com
github.com/malnick
@malnick
technoblogic.io
srcclr.com | @srcclr
c at c4 dot vc
paul at srcclr dot com
github.com/cl4r1ty
@cl4r1ty
c4.vc

More Related Content

What's hot

Node.js: Continuation-Local-Storage and the Magic of AsyncListener
Node.js: Continuation-Local-Storage and the Magic of AsyncListenerNode.js: Continuation-Local-Storage and the Magic of AsyncListener
Node.js: Continuation-Local-Storage and the Magic of AsyncListener
Islam Sharabash
 
FP - Découverte de Play Framework Scala
FP - Découverte de Play Framework ScalaFP - Découverte de Play Framework Scala
FP - Découverte de Play Framework Scala
Kévin Margueritte
 
Vue.js + Django - configuración para desarrollo con webpack y HMR
Vue.js + Django - configuración para desarrollo con webpack y HMRVue.js + Django - configuración para desarrollo con webpack y HMR
Vue.js + Django - configuración para desarrollo con webpack y HMR
Javier Abadía
 
What's new in jQuery 1.5
What's new in jQuery 1.5What's new in jQuery 1.5
What's new in jQuery 1.5
Martin Kleppe
 
PostgreSQL Open SV 2018
PostgreSQL Open SV 2018PostgreSQL Open SV 2018
PostgreSQL Open SV 2018
artgillespie
 
Stratalux Cloud Formation and Chef Integration Presentation
Stratalux Cloud Formation and Chef Integration PresentationStratalux Cloud Formation and Chef Integration Presentation
Stratalux Cloud Formation and Chef Integration PresentationJeremy Przygode
 
Managing State in React Apps with RxJS by James Wright at FrontCon 2019
Managing State in React Apps with RxJS by James Wright at FrontCon 2019Managing State in React Apps with RxJS by James Wright at FrontCon 2019
Managing State in React Apps with RxJS by James Wright at FrontCon 2019
DevClub_lv
 
Reactive, component 그리고 angular2
Reactive, component 그리고  angular2Reactive, component 그리고  angular2
Reactive, component 그리고 angular2
Jeado Ko
 
リローダブルClojureアプリケーション
リローダブルClojureアプリケーションリローダブルClojureアプリケーション
リローダブルClojureアプリケーション
Kenji Nakamura
 
Cassandra Summit 2015
Cassandra Summit 2015Cassandra Summit 2015
Cassandra Summit 2015
jbellis
 
Basic Tutorial of React for Programmers
Basic Tutorial of React for ProgrammersBasic Tutorial of React for Programmers
Basic Tutorial of React for Programmers
David Rodenas
 
JavaFX 2.0 With Alternative Languages - Groovy, Clojure, Scala, Fantom, and V...
JavaFX 2.0 With Alternative Languages - Groovy, Clojure, Scala, Fantom, and V...JavaFX 2.0 With Alternative Languages - Groovy, Clojure, Scala, Fantom, and V...
JavaFX 2.0 With Alternative Languages - Groovy, Clojure, Scala, Fantom, and V...
Stephen Chin
 
Developing web-apps like it's 2013
Developing web-apps like it's 2013Developing web-apps like it's 2013
Developing web-apps like it's 2013
Laurent_VB
 
FalsyValues. Dmitry Soshnikov - ECMAScript 6
FalsyValues. Dmitry Soshnikov - ECMAScript 6FalsyValues. Dmitry Soshnikov - ECMAScript 6
FalsyValues. Dmitry Soshnikov - ECMAScript 6
Dmitry Soshnikov
 
Scalable Angular 2 Application Architecture
Scalable Angular 2 Application ArchitectureScalable Angular 2 Application Architecture
Scalable Angular 2 Application Architecture
FDConf
 
Play vs Rails
Play vs RailsPlay vs Rails
Play vs Rails
Daniel Cukier
 
Cutting Edge Data Processing with PHP & XQuery
Cutting Edge Data Processing with PHP & XQueryCutting Edge Data Processing with PHP & XQuery
Cutting Edge Data Processing with PHP & XQuery
William Candillon
 

What's hot (20)

Not your Grandma's XQuery
Not your Grandma's XQueryNot your Grandma's XQuery
Not your Grandma's XQuery
 
Node.js: Continuation-Local-Storage and the Magic of AsyncListener
Node.js: Continuation-Local-Storage and the Magic of AsyncListenerNode.js: Continuation-Local-Storage and the Magic of AsyncListener
Node.js: Continuation-Local-Storage and the Magic of AsyncListener
 
FP - Découverte de Play Framework Scala
FP - Découverte de Play Framework ScalaFP - Découverte de Play Framework Scala
FP - Découverte de Play Framework Scala
 
Vue.js + Django - configuración para desarrollo con webpack y HMR
Vue.js + Django - configuración para desarrollo con webpack y HMRVue.js + Django - configuración para desarrollo con webpack y HMR
Vue.js + Django - configuración para desarrollo con webpack y HMR
 
What's new in jQuery 1.5
What's new in jQuery 1.5What's new in jQuery 1.5
What's new in jQuery 1.5
 
PostgreSQL Open SV 2018
PostgreSQL Open SV 2018PostgreSQL Open SV 2018
PostgreSQL Open SV 2018
 
Scala active record
Scala active recordScala active record
Scala active record
 
Aimaf
AimafAimaf
Aimaf
 
Stratalux Cloud Formation and Chef Integration Presentation
Stratalux Cloud Formation and Chef Integration PresentationStratalux Cloud Formation and Chef Integration Presentation
Stratalux Cloud Formation and Chef Integration Presentation
 
Managing State in React Apps with RxJS by James Wright at FrontCon 2019
Managing State in React Apps with RxJS by James Wright at FrontCon 2019Managing State in React Apps with RxJS by James Wright at FrontCon 2019
Managing State in React Apps with RxJS by James Wright at FrontCon 2019
 
Reactive, component 그리고 angular2
Reactive, component 그리고  angular2Reactive, component 그리고  angular2
Reactive, component 그리고 angular2
 
リローダブルClojureアプリケーション
リローダブルClojureアプリケーションリローダブルClojureアプリケーション
リローダブルClojureアプリケーション
 
Cassandra Summit 2015
Cassandra Summit 2015Cassandra Summit 2015
Cassandra Summit 2015
 
Basic Tutorial of React for Programmers
Basic Tutorial of React for ProgrammersBasic Tutorial of React for Programmers
Basic Tutorial of React for Programmers
 
JavaFX 2.0 With Alternative Languages - Groovy, Clojure, Scala, Fantom, and V...
JavaFX 2.0 With Alternative Languages - Groovy, Clojure, Scala, Fantom, and V...JavaFX 2.0 With Alternative Languages - Groovy, Clojure, Scala, Fantom, and V...
JavaFX 2.0 With Alternative Languages - Groovy, Clojure, Scala, Fantom, and V...
 
Developing web-apps like it's 2013
Developing web-apps like it's 2013Developing web-apps like it's 2013
Developing web-apps like it's 2013
 
FalsyValues. Dmitry Soshnikov - ECMAScript 6
FalsyValues. Dmitry Soshnikov - ECMAScript 6FalsyValues. Dmitry Soshnikov - ECMAScript 6
FalsyValues. Dmitry Soshnikov - ECMAScript 6
 
Scalable Angular 2 Application Architecture
Scalable Angular 2 Application ArchitectureScalable Angular 2 Application Architecture
Scalable Angular 2 Application Architecture
 
Play vs Rails
Play vs RailsPlay vs Rails
Play vs Rails
 
Cutting Edge Data Processing with PHP & XQuery
Cutting Edge Data Processing with PHP & XQueryCutting Edge Data Processing with PHP & XQuery
Cutting Edge Data Processing with PHP & XQuery
 

Viewers also liked

Incêndios
IncêndiosIncêndios
Incêndios
ric pt
 
Segurança ativa e passiva
Segurança ativa e passivaSegurança ativa e passiva
Segurança ativa e passiva
ric pt
 
dental bridges
dental bridgesdental bridges
2.2.3 syariah muamalat
2.2.3 syariah muamalat2.2.3 syariah muamalat
2.2.3 syariah muamalat
smka kota kinabalu, sabah
 
El rol del cristiano en el mundo
El rol del cristiano en el mundoEl rol del cristiano en el mundo
El rol del cristiano en el mundo
Norith Ramos Vela
 
11 how do you grow a premium brand (1)
11 how do you grow a premium brand (1)11 how do you grow a premium brand (1)
11 how do you grow a premium brand (1)
Manpreet Kaur
 
244796993 triptico-de-senales-1-pdf
244796993 triptico-de-senales-1-pdf244796993 triptico-de-senales-1-pdf
244796993 triptico-de-senales-1-pdf
ana marin
 
снежная королева
снежная королеваснежная королева
снежная королева
GBDOU №51
 
NOM-011-STPS-2001 y NOM-024-STPS-2001 (mapa conceptual)
NOM-011-STPS-2001 y NOM-024-STPS-2001 (mapa conceptual)NOM-011-STPS-2001 y NOM-024-STPS-2001 (mapa conceptual)
NOM-011-STPS-2001 y NOM-024-STPS-2001 (mapa conceptual)
Carlos Ernesto Custodio Cadena
 
презентация транспорт
презентация транспортпрезентация транспорт
презентация транспорт
GBDOU №51
 
Short films Presentation
Short films PresentationShort films Presentation
Short films Presentation
Skye O'Neill
 
#WeAreTravel15 - Conférence SEO
#WeAreTravel15 - Conférence SEO #WeAreTravel15 - Conférence SEO
#WeAreTravel15 - Conférence SEO
My Bloggers Company
 

Viewers also liked (15)

essay3R
essay3Ressay3R
essay3R
 
Incêndios
IncêndiosIncêndios
Incêndios
 
Segurança ativa e passiva
Segurança ativa e passivaSegurança ativa e passiva
Segurança ativa e passiva
 
dental bridges
dental bridgesdental bridges
dental bridges
 
Trigonometría
TrigonometríaTrigonometría
Trigonometría
 
2.2.3 syariah muamalat
2.2.3 syariah muamalat2.2.3 syariah muamalat
2.2.3 syariah muamalat
 
El rol del cristiano en el mundo
El rol del cristiano en el mundoEl rol del cristiano en el mundo
El rol del cristiano en el mundo
 
11 how do you grow a premium brand (1)
11 how do you grow a premium brand (1)11 how do you grow a premium brand (1)
11 how do you grow a premium brand (1)
 
244796993 triptico-de-senales-1-pdf
244796993 triptico-de-senales-1-pdf244796993 triptico-de-senales-1-pdf
244796993 triptico-de-senales-1-pdf
 
снежная королева
снежная королеваснежная королева
снежная королева
 
Zimnie zabavy
Zimnie zabavyZimnie zabavy
Zimnie zabavy
 
NOM-011-STPS-2001 y NOM-024-STPS-2001 (mapa conceptual)
NOM-011-STPS-2001 y NOM-024-STPS-2001 (mapa conceptual)NOM-011-STPS-2001 y NOM-024-STPS-2001 (mapa conceptual)
NOM-011-STPS-2001 y NOM-024-STPS-2001 (mapa conceptual)
 
презентация транспорт
презентация транспортпрезентация транспорт
презентация транспорт
 
Short films Presentation
Short films PresentationShort films Presentation
Short films Presentation
 
#WeAreTravel15 - Conférence SEO
#WeAreTravel15 - Conférence SEO #WeAreTravel15 - Conférence SEO
#WeAreTravel15 - Conférence SEO
 

Similar to Vertically Scaled Design Patters

Coolblue - Behind the Scenes Continuous Integration & Deployment
Coolblue - Behind the Scenes Continuous Integration & DeploymentCoolblue - Behind the Scenes Continuous Integration & Deployment
Coolblue - Behind the Scenes Continuous Integration & Deployment
Matthew Hodgkins
 
Easy Cloud Native Transformation using HashiCorp Nomad
Easy Cloud Native Transformation using HashiCorp NomadEasy Cloud Native Transformation using HashiCorp Nomad
Easy Cloud Native Transformation using HashiCorp Nomad
Bram Vogelaar
 
MongoDB World 2019: Life In Stitch-es
MongoDB World 2019: Life In Stitch-esMongoDB World 2019: Life In Stitch-es
MongoDB World 2019: Life In Stitch-es
MongoDB
 
It's Time to Get Ready for the Power of PL/SQL and JavaScript Combined
It's Time to Get Ready for the Power  of PL/SQL and JavaScript CombinedIt's Time to Get Ready for the Power  of PL/SQL and JavaScript Combined
It's Time to Get Ready for the Power of PL/SQL and JavaScript Combined
Rodrigo Mesquita
 
AngularJS and SPA
AngularJS and SPAAngularJS and SPA
AngularJS and SPA
Lorenzo Dematté
 
Cutting through the fog of cloud
Cutting through the fog of cloudCutting through the fog of cloud
Cutting through the fog of cloud
Kyle Rames
 
SproutCore and the Future of Web Apps
SproutCore and the Future of Web AppsSproutCore and the Future of Web Apps
SproutCore and the Future of Web Apps
Mike Subelsky
 
NYC* 2013 - "Advanced Data Processing: Beyond Queries and Slices"
NYC* 2013 - "Advanced Data Processing: Beyond Queries and Slices"NYC* 2013 - "Advanced Data Processing: Beyond Queries and Slices"
NYC* 2013 - "Advanced Data Processing: Beyond Queries and Slices"
DataStax Academy
 
Intravert Server side processing for Cassandra
Intravert Server side processing for CassandraIntravert Server side processing for Cassandra
Intravert Server side processing for Cassandra
Edward Capriolo
 
2019 hashiconf consul-templaterb
2019 hashiconf consul-templaterb2019 hashiconf consul-templaterb
2019 hashiconf consul-templaterb
Pierre Souchay
 
OpenERP e l'arte della gestione aziendale con Python
OpenERP e l'arte della gestione aziendale con PythonOpenERP e l'arte della gestione aziendale con Python
OpenERP e l'arte della gestione aziendale con Python
PyCon Italia
 
MEAN - Notes from the field (Full-Stack Development with Javascript)
MEAN - Notes from the field (Full-Stack Development with Javascript)MEAN - Notes from the field (Full-Stack Development with Javascript)
MEAN - Notes from the field (Full-Stack Development with Javascript)
Chris Clarke
 
AngularJs
AngularJsAngularJs
AngularJs
Hossein Baghayi
 
Future Decoded - Node.js per sviluppatori .NET
Future Decoded - Node.js per sviluppatori .NETFuture Decoded - Node.js per sviluppatori .NET
Future Decoded - Node.js per sviluppatori .NET
Gianluca Carucci
 
Oliver leech cloudstack
Oliver leech   cloudstackOliver leech   cloudstack
Oliver leech cloudstack
ShapeBlue
 
AngularJS
AngularJSAngularJS
AngularJS
LearningTech
 
Security on Rails
Security on RailsSecurity on Rails
Security on RailsDavid Paluy
 
Basics of AngularJS
Basics of AngularJSBasics of AngularJS
Basics of AngularJS
Filip Janevski
 
Jenkins Online Meetup - Automated SLI based Build Validation with Keptn
Jenkins Online Meetup - Automated SLI based Build Validation with KeptnJenkins Online Meetup - Automated SLI based Build Validation with Keptn
Jenkins Online Meetup - Automated SLI based Build Validation with Keptn
Andreas Grabner
 

Similar to Vertically Scaled Design Patters (20)

Coolblue - Behind the Scenes Continuous Integration & Deployment
Coolblue - Behind the Scenes Continuous Integration & DeploymentCoolblue - Behind the Scenes Continuous Integration & Deployment
Coolblue - Behind the Scenes Continuous Integration & Deployment
 
Easy Cloud Native Transformation using HashiCorp Nomad
Easy Cloud Native Transformation using HashiCorp NomadEasy Cloud Native Transformation using HashiCorp Nomad
Easy Cloud Native Transformation using HashiCorp Nomad
 
MongoDB World 2019: Life In Stitch-es
MongoDB World 2019: Life In Stitch-esMongoDB World 2019: Life In Stitch-es
MongoDB World 2019: Life In Stitch-es
 
It's Time to Get Ready for the Power of PL/SQL and JavaScript Combined
It's Time to Get Ready for the Power  of PL/SQL and JavaScript CombinedIt's Time to Get Ready for the Power  of PL/SQL and JavaScript Combined
It's Time to Get Ready for the Power of PL/SQL and JavaScript Combined
 
AngularJS and SPA
AngularJS and SPAAngularJS and SPA
AngularJS and SPA
 
Cutting through the fog of cloud
Cutting through the fog of cloudCutting through the fog of cloud
Cutting through the fog of cloud
 
Pyrax talk
Pyrax talkPyrax talk
Pyrax talk
 
SproutCore and the Future of Web Apps
SproutCore and the Future of Web AppsSproutCore and the Future of Web Apps
SproutCore and the Future of Web Apps
 
NYC* 2013 - "Advanced Data Processing: Beyond Queries and Slices"
NYC* 2013 - "Advanced Data Processing: Beyond Queries and Slices"NYC* 2013 - "Advanced Data Processing: Beyond Queries and Slices"
NYC* 2013 - "Advanced Data Processing: Beyond Queries and Slices"
 
Intravert Server side processing for Cassandra
Intravert Server side processing for CassandraIntravert Server side processing for Cassandra
Intravert Server side processing for Cassandra
 
2019 hashiconf consul-templaterb
2019 hashiconf consul-templaterb2019 hashiconf consul-templaterb
2019 hashiconf consul-templaterb
 
OpenERP e l'arte della gestione aziendale con Python
OpenERP e l'arte della gestione aziendale con PythonOpenERP e l'arte della gestione aziendale con Python
OpenERP e l'arte della gestione aziendale con Python
 
MEAN - Notes from the field (Full-Stack Development with Javascript)
MEAN - Notes from the field (Full-Stack Development with Javascript)MEAN - Notes from the field (Full-Stack Development with Javascript)
MEAN - Notes from the field (Full-Stack Development with Javascript)
 
AngularJs
AngularJsAngularJs
AngularJs
 
Future Decoded - Node.js per sviluppatori .NET
Future Decoded - Node.js per sviluppatori .NETFuture Decoded - Node.js per sviluppatori .NET
Future Decoded - Node.js per sviluppatori .NET
 
Oliver leech cloudstack
Oliver leech   cloudstackOliver leech   cloudstack
Oliver leech cloudstack
 
AngularJS
AngularJSAngularJS
AngularJS
 
Security on Rails
Security on RailsSecurity on Rails
Security on Rails
 
Basics of AngularJS
Basics of AngularJSBasics of AngularJS
Basics of AngularJS
 
Jenkins Online Meetup - Automated SLI based Build Validation with Keptn
Jenkins Online Meetup - Automated SLI based Build Validation with KeptnJenkins Online Meetup - Automated SLI based Build Validation with Keptn
Jenkins Online Meetup - Automated SLI based Build Validation with Keptn
 

More from Jeff Malnick

Continuous integration with_puppet
Continuous integration with_puppetContinuous integration with_puppet
Continuous integration with_puppet
Jeff Malnick
 
Showoff preso 0023
Showoff preso 0023Showoff preso 0023
Showoff preso 0023Jeff Malnick
 
Showoff preso 0022
Showoff preso 0022Showoff preso 0022
Showoff preso 0022Jeff Malnick
 
Showoff preso 0024
Showoff preso 0024Showoff preso 0024
Showoff preso 0024Jeff Malnick
 
Showoff preso 0026
Showoff preso 0026Showoff preso 0026
Showoff preso 0026Jeff Malnick
 
Showoff preso 0028
Showoff preso 0028Showoff preso 0028
Showoff preso 0028Jeff Malnick
 
Showoff preso 0029
Showoff preso 0029Showoff preso 0029
Showoff preso 0029Jeff Malnick
 
Showoff preso 0039
Showoff preso 0039Showoff preso 0039
Showoff preso 0039Jeff Malnick
 
Showoff preso 0030
Showoff preso 0030Showoff preso 0030
Showoff preso 0030Jeff Malnick
 
Showoff preso 0031
Showoff preso 0031Showoff preso 0031
Showoff preso 0031Jeff Malnick
 
Showoff preso 0032
Showoff preso 0032Showoff preso 0032
Showoff preso 0032Jeff Malnick
 
Showoff preso 0034
Showoff preso 0034Showoff preso 0034
Showoff preso 0034Jeff Malnick
 
Showoff preso 0035
Showoff preso 0035Showoff preso 0035
Showoff preso 0035Jeff Malnick
 
Showoff preso 0037
Showoff preso 0037Showoff preso 0037
Showoff preso 0037Jeff Malnick
 
Showoff preso 0038
Showoff preso 0038Showoff preso 0038
Showoff preso 0038Jeff Malnick
 
Showoff preso 0040
Showoff preso 0040Showoff preso 0040
Showoff preso 0040Jeff Malnick
 
Showoff preso 0041
Showoff preso 0041Showoff preso 0041
Showoff preso 0041Jeff Malnick
 
Showoff preso 0042
Showoff preso 0042Showoff preso 0042
Showoff preso 0042Jeff Malnick
 
Showoff preso 0043
Showoff preso 0043Showoff preso 0043
Showoff preso 0043Jeff Malnick
 
Showoff preso 0044
Showoff preso 0044Showoff preso 0044
Showoff preso 0044Jeff Malnick
 

More from Jeff Malnick (20)

Continuous integration with_puppet
Continuous integration with_puppetContinuous integration with_puppet
Continuous integration with_puppet
 
Showoff preso 0023
Showoff preso 0023Showoff preso 0023
Showoff preso 0023
 
Showoff preso 0022
Showoff preso 0022Showoff preso 0022
Showoff preso 0022
 
Showoff preso 0024
Showoff preso 0024Showoff preso 0024
Showoff preso 0024
 
Showoff preso 0026
Showoff preso 0026Showoff preso 0026
Showoff preso 0026
 
Showoff preso 0028
Showoff preso 0028Showoff preso 0028
Showoff preso 0028
 
Showoff preso 0029
Showoff preso 0029Showoff preso 0029
Showoff preso 0029
 
Showoff preso 0039
Showoff preso 0039Showoff preso 0039
Showoff preso 0039
 
Showoff preso 0030
Showoff preso 0030Showoff preso 0030
Showoff preso 0030
 
Showoff preso 0031
Showoff preso 0031Showoff preso 0031
Showoff preso 0031
 
Showoff preso 0032
Showoff preso 0032Showoff preso 0032
Showoff preso 0032
 
Showoff preso 0034
Showoff preso 0034Showoff preso 0034
Showoff preso 0034
 
Showoff preso 0035
Showoff preso 0035Showoff preso 0035
Showoff preso 0035
 
Showoff preso 0037
Showoff preso 0037Showoff preso 0037
Showoff preso 0037
 
Showoff preso 0038
Showoff preso 0038Showoff preso 0038
Showoff preso 0038
 
Showoff preso 0040
Showoff preso 0040Showoff preso 0040
Showoff preso 0040
 
Showoff preso 0041
Showoff preso 0041Showoff preso 0041
Showoff preso 0041
 
Showoff preso 0042
Showoff preso 0042Showoff preso 0042
Showoff preso 0042
 
Showoff preso 0043
Showoff preso 0043Showoff preso 0043
Showoff preso 0043
 
Showoff preso 0044
Showoff preso 0044Showoff preso 0044
Showoff preso 0044
 

Recently uploaded

ethical hacking-mobile hacking methods.ppt
ethical hacking-mobile hacking methods.pptethical hacking-mobile hacking methods.ppt
ethical hacking-mobile hacking methods.ppt
Jayaprasanna4
 
ASME IX(9) 2007 Full Version .pdf
ASME IX(9)  2007 Full Version       .pdfASME IX(9)  2007 Full Version       .pdf
ASME IX(9) 2007 Full Version .pdf
AhmedHussein950959
 
power quality voltage fluctuation UNIT - I.pptx
power quality voltage fluctuation UNIT - I.pptxpower quality voltage fluctuation UNIT - I.pptx
power quality voltage fluctuation UNIT - I.pptx
ViniHema
 
H.Seo, ICLR 2024, MLILAB, KAIST AI.pdf
H.Seo,  ICLR 2024, MLILAB,  KAIST AI.pdfH.Seo,  ICLR 2024, MLILAB,  KAIST AI.pdf
H.Seo, ICLR 2024, MLILAB, KAIST AI.pdf
MLILAB
 
Top 10 Oil and Gas Projects in Saudi Arabia 2024.pdf
Top 10 Oil and Gas Projects in Saudi Arabia 2024.pdfTop 10 Oil and Gas Projects in Saudi Arabia 2024.pdf
Top 10 Oil and Gas Projects in Saudi Arabia 2024.pdf
Teleport Manpower Consultant
 
Industrial Training at Shahjalal Fertilizer Company Limited (SFCL)
Industrial Training at Shahjalal Fertilizer Company Limited (SFCL)Industrial Training at Shahjalal Fertilizer Company Limited (SFCL)
Industrial Training at Shahjalal Fertilizer Company Limited (SFCL)
MdTanvirMahtab2
 
The role of big data in decision making.
The role of big data in decision making.The role of big data in decision making.
The role of big data in decision making.
ankuprajapati0525
 
Courier management system project report.pdf
Courier management system project report.pdfCourier management system project report.pdf
Courier management system project report.pdf
Kamal Acharya
 
Railway Signalling Principles Edition 3.pdf
Railway Signalling Principles Edition 3.pdfRailway Signalling Principles Edition 3.pdf
Railway Signalling Principles Edition 3.pdf
TeeVichai
 
Planning Of Procurement o different goods and services
Planning Of Procurement o different goods and servicesPlanning Of Procurement o different goods and services
Planning Of Procurement o different goods and services
JoytuBarua2
 
Forklift Classes Overview by Intella Parts
Forklift Classes Overview by Intella PartsForklift Classes Overview by Intella Parts
Forklift Classes Overview by Intella Parts
Intella Parts
 
Event Management System Vb Net Project Report.pdf
Event Management System Vb Net  Project Report.pdfEvent Management System Vb Net  Project Report.pdf
Event Management System Vb Net Project Report.pdf
Kamal Acharya
 
Gen AI Study Jams _ For the GDSC Leads in India.pdf
Gen AI Study Jams _ For the GDSC Leads in India.pdfGen AI Study Jams _ For the GDSC Leads in India.pdf
Gen AI Study Jams _ For the GDSC Leads in India.pdf
gdsczhcet
 
Final project report on grocery store management system..pdf
Final project report on grocery store management system..pdfFinal project report on grocery store management system..pdf
Final project report on grocery store management system..pdf
Kamal Acharya
 
AKS UNIVERSITY Satna Final Year Project By OM Hardaha.pdf
AKS UNIVERSITY Satna Final Year Project By OM Hardaha.pdfAKS UNIVERSITY Satna Final Year Project By OM Hardaha.pdf
AKS UNIVERSITY Satna Final Year Project By OM Hardaha.pdf
SamSarthak3
 
在线办理(ANU毕业证书)澳洲国立大学毕业证录取通知书一模一样
在线办理(ANU毕业证书)澳洲国立大学毕业证录取通知书一模一样在线办理(ANU毕业证书)澳洲国立大学毕业证录取通知书一模一样
在线办理(ANU毕业证书)澳洲国立大学毕业证录取通知书一模一样
obonagu
 
Cosmetic shop management system project report.pdf
Cosmetic shop management system project report.pdfCosmetic shop management system project report.pdf
Cosmetic shop management system project report.pdf
Kamal Acharya
 
COLLEGE BUS MANAGEMENT SYSTEM PROJECT REPORT.pdf
COLLEGE BUS MANAGEMENT SYSTEM PROJECT REPORT.pdfCOLLEGE BUS MANAGEMENT SYSTEM PROJECT REPORT.pdf
COLLEGE BUS MANAGEMENT SYSTEM PROJECT REPORT.pdf
Kamal Acharya
 
CME397 Surface Engineering- Professional Elective
CME397 Surface Engineering- Professional ElectiveCME397 Surface Engineering- Professional Elective
CME397 Surface Engineering- Professional Elective
karthi keyan
 
DESIGN A COTTON SEED SEPARATION MACHINE.docx
DESIGN A COTTON SEED SEPARATION MACHINE.docxDESIGN A COTTON SEED SEPARATION MACHINE.docx
DESIGN A COTTON SEED SEPARATION MACHINE.docx
FluxPrime1
 

Recently uploaded (20)

ethical hacking-mobile hacking methods.ppt
ethical hacking-mobile hacking methods.pptethical hacking-mobile hacking methods.ppt
ethical hacking-mobile hacking methods.ppt
 
ASME IX(9) 2007 Full Version .pdf
ASME IX(9)  2007 Full Version       .pdfASME IX(9)  2007 Full Version       .pdf
ASME IX(9) 2007 Full Version .pdf
 
power quality voltage fluctuation UNIT - I.pptx
power quality voltage fluctuation UNIT - I.pptxpower quality voltage fluctuation UNIT - I.pptx
power quality voltage fluctuation UNIT - I.pptx
 
H.Seo, ICLR 2024, MLILAB, KAIST AI.pdf
H.Seo,  ICLR 2024, MLILAB,  KAIST AI.pdfH.Seo,  ICLR 2024, MLILAB,  KAIST AI.pdf
H.Seo, ICLR 2024, MLILAB, KAIST AI.pdf
 
Top 10 Oil and Gas Projects in Saudi Arabia 2024.pdf
Top 10 Oil and Gas Projects in Saudi Arabia 2024.pdfTop 10 Oil and Gas Projects in Saudi Arabia 2024.pdf
Top 10 Oil and Gas Projects in Saudi Arabia 2024.pdf
 
Industrial Training at Shahjalal Fertilizer Company Limited (SFCL)
Industrial Training at Shahjalal Fertilizer Company Limited (SFCL)Industrial Training at Shahjalal Fertilizer Company Limited (SFCL)
Industrial Training at Shahjalal Fertilizer Company Limited (SFCL)
 
The role of big data in decision making.
The role of big data in decision making.The role of big data in decision making.
The role of big data in decision making.
 
Courier management system project report.pdf
Courier management system project report.pdfCourier management system project report.pdf
Courier management system project report.pdf
 
Railway Signalling Principles Edition 3.pdf
Railway Signalling Principles Edition 3.pdfRailway Signalling Principles Edition 3.pdf
Railway Signalling Principles Edition 3.pdf
 
Planning Of Procurement o different goods and services
Planning Of Procurement o different goods and servicesPlanning Of Procurement o different goods and services
Planning Of Procurement o different goods and services
 
Forklift Classes Overview by Intella Parts
Forklift Classes Overview by Intella PartsForklift Classes Overview by Intella Parts
Forklift Classes Overview by Intella Parts
 
Event Management System Vb Net Project Report.pdf
Event Management System Vb Net  Project Report.pdfEvent Management System Vb Net  Project Report.pdf
Event Management System Vb Net Project Report.pdf
 
Gen AI Study Jams _ For the GDSC Leads in India.pdf
Gen AI Study Jams _ For the GDSC Leads in India.pdfGen AI Study Jams _ For the GDSC Leads in India.pdf
Gen AI Study Jams _ For the GDSC Leads in India.pdf
 
Final project report on grocery store management system..pdf
Final project report on grocery store management system..pdfFinal project report on grocery store management system..pdf
Final project report on grocery store management system..pdf
 
AKS UNIVERSITY Satna Final Year Project By OM Hardaha.pdf
AKS UNIVERSITY Satna Final Year Project By OM Hardaha.pdfAKS UNIVERSITY Satna Final Year Project By OM Hardaha.pdf
AKS UNIVERSITY Satna Final Year Project By OM Hardaha.pdf
 
在线办理(ANU毕业证书)澳洲国立大学毕业证录取通知书一模一样
在线办理(ANU毕业证书)澳洲国立大学毕业证录取通知书一模一样在线办理(ANU毕业证书)澳洲国立大学毕业证录取通知书一模一样
在线办理(ANU毕业证书)澳洲国立大学毕业证录取通知书一模一样
 
Cosmetic shop management system project report.pdf
Cosmetic shop management system project report.pdfCosmetic shop management system project report.pdf
Cosmetic shop management system project report.pdf
 
COLLEGE BUS MANAGEMENT SYSTEM PROJECT REPORT.pdf
COLLEGE BUS MANAGEMENT SYSTEM PROJECT REPORT.pdfCOLLEGE BUS MANAGEMENT SYSTEM PROJECT REPORT.pdf
COLLEGE BUS MANAGEMENT SYSTEM PROJECT REPORT.pdf
 
CME397 Surface Engineering- Professional Elective
CME397 Surface Engineering- Professional ElectiveCME397 Surface Engineering- Professional Elective
CME397 Surface Engineering- Professional Elective
 
DESIGN A COTTON SEED SEPARATION MACHINE.docx
DESIGN A COTTON SEED SEPARATION MACHINE.docxDESIGN A COTTON SEED SEPARATION MACHINE.docx
DESIGN A COTTON SEED SEPARATION MACHINE.docx
 

Vertically Scaled Design Patters

  • 1. Vertically Scaled Design Patterns Jeff Malnick & Paul Ambrosini Systems Engineering @ SRC:CLR srcclr.com | @srcclr
  • 2. How this is going down: srcclr.com | @srcclr ● History & Evolution ● Principles ● Notes & Examples ● Demo
  • 4. In the beginning there was srcclr.com | @srcclr ● AWS ● ELB ● Ansible ● SCP ● Tomcat ● We all start somewhere
  • 6. srcclr.com | @srcclr Paul heroically rolled it out in 2 weeks
  • 7. Massive Gains srcclr.com | @srcclr ● Huge improvement ● Split up Frontend and Backend Code ● Teams deploying separately ● Productivity went up dramatically
  • 8. Wasn’t perfect srcclr.com | @srcclr ● Not fully dynamic ● CI hooks not perfect ● Cookbook merging* ● Service health management lacking
  • 9. Then we migrated... srcclr.com | @srcclr ● *hired Jeff ○ ‘ops role’ ○ or ‘devops’
  • 10. We got a shiny new CM system. srcclr.com | @srcclr
  • 11. "Type" : "AWS::EC2::Instance", "Properties" : { "KeyName" : "secure", "SecurityGroupIds" : ["sg-1234abcd","sg-5678efg"], "SubnetId" : "subnet-1234abcd", "UserData" : { "Fn::Base64" : { "Fn::Join" : ["", [ "#!/bin/sh -vn", "ROLE='qa_nginx_static'n", "MASTER='https://puppet.srcclr.com'n", "D_ROLE=$(echo $ROLE | tr '_' '-')n", "D_IP=$(hostname -I | tr '.' '-' | cut -d' ' -f1)n", "HOSTNAME="$(echo $D_ROLE)-$(echo $D_IP)"n", "echo "127.0.0.1 $HOSTNAME" >> /etc/hosts", "apt-get updaten", "echo $HOSTNAME > /etc/hostnamen", "/bin/hostname $HOSTNAMEn", "echo $ROLE > /etc/rolen", "sudo curl -k $MASTER:8140/packages/current/install.bash | sudo bashn" ]]} Cloud Formation for Bare Metal
  • 13. srcclr.com | @srcclr # Executed in $WORKSPACE on jenkins VERSION=$(some_mvn_command) curl -X POST -d@- puppet.myorg.com:1015/deploy <<EOF { "service": "analytics", "version": "$VERSION", "environment": "qa", "role": "qa_service" } EOF How we do CI
  • 14. New CM was better but... srcclr.com | @srcclr
  • 15. Shameless use of hooks srcclr.com | @srcclr include http http::listener {‘kick_haproxy’: port => '1234', routes => { 'kick_haproxy' => { 'method' => 'get', 'command' => "su - peadmin -c 'mco puppet runonce -F role == haproxy_internal'" },
  • 16. “Service Discovery” srcclr.com | @srcclr http { 'kick_haproxy': ensure => get, port => '1234', fqdn => 'puppet.myorg.com' }
  • 17. srcclr.com | @srcclr sc_services::service { 'librarian': deploy_stage => 'production', version => $version, enable_newrelic_apm => true, loadbalancer_role => 'production_internal', xmx_setting => '1024', xms_setting => '1024', proc_opts => { '1' => { 'env_profile' => 'prod', 'port' => '11100', 'mgmt_port' => '11110', 'override' => $properties_file, }, '2' => { 'env_profile' => 'prod', 'port' => '11101', 'mgmt_port' => '11111', 'override' => $properties_file, } } Still static...
  • 18. srcclr.com | @srcclr sc_services::service { 'librarian': deploy_stage => 'app', version => $version, enable_newrelic_apm => true, loadbalancer_role => 'production_internal', xmx_setting => '1024', xms_setting => '1024', proc_opts => { '1' => { 'env_profile' => 'app', 'port' => '11100', 'mgmt_port' => '11110', 'override' => $properties_file, }, '2' => { 'env_profile' => 'app', 'port' => '11101', 'mgmt_port' => '11111', 'override' => $properties_file, } } Still static... {Statically assigning ports!
  • 19. srcclr.com | @srcclr sc_services::service { 'librarian': deploy_stage => 'app', version => $version, enable_newrelic_apm => true, loadbalancer_role => 'production_internal', xmx_setting => '1024', xms_setting => '1024', proc_opts => { '1' => { 'env_profile' => 'app', 'port' => '11100', 'mgmt_port' => '11110', 'override' => $properties_file, }, '2' => { 'env_profile' => 'app', 'port' => '11101', 'mgmt_port' => '11111', 'override' => $properties_file, } } Still static... What S3 Bucket is this Jar from?
  • 20. srcclr.com | @srcclr sc_services::service { 'librarian': deploy_stage => 'app', version => $version, enable_newrelic_apm => true, loadbalancer_role => 'production_internal', xmx_setting => '1024', xms_setting => '1024', proc_opts => { '1' => { 'env_profile' => 'app', 'port' => '11100', 'mgmt_port' => '11110', 'override' => $properties_file, }, '2' => { 'env_profile' => 'app', 'port' => '11101', 'mgmt_port' => '11111', 'override' => $properties_file, } } Still static... “Service Discovery” for HaProxy
  • 21. srcclr.com | @srcclr sc_services::service { 'librarian': deploy_stage => 'app', version => $version, enable_newrelic_apm => true, loadbalancer_role => 'production_internal', xmx_setting => '1024', xms_setting => '1024', proc_opts => { '1' => { 'env_profile' => 'app', 'port' => '11100', 'mgmt_port' => '11110', 'override' => $properties_file, }, '2' => { 'env_profile' => 'app', 'port' => '11101', 'mgmt_port' => '11111', 'override' => $properties_file, } } Still static... Service statically scheduled to execute on a node classified by Puppet
  • 22. “Scaling” srcclr.com | @srcclr $ports = { 'librarian' => { 'svc' => '20060-20070', 'mgmt' => '20071-20080', }, 'notifications' => { 'svc' => '20000-20010', 'mgmt' => '20011-20020', }, 'cloud_agent' => { 'svc' => '31040-31050', 'mgmt' => '31051-31060', }, 'search' => { 'svc' => '41140-41150', 'mgmt' => '41151-41160', },
  • 23. “Scaling” srcclr.com | @srcclr $ports = { 'librarian' => { 'svc' => '20060-20070', 'mgmt' => '20071-20080', }, 'notifications' => { 'svc' => '20000-20010', 'mgmt' => '20011-20020', }, 'cloud_agent' => { 'svc' => '31040-31050', 'mgmt' => '31051-31060', }, 'search' => { 'svc' => '41140-41150', 'mgmt' => '41151-41160', } ... { Scaling to maximum of 10 instances per box.
  • 24. Recap srcclr.com | @srcclr ● CM statically schedules services to run on node ● Can scale to maximum number of known ports ● This does “scale” vertically & horizontally...
  • 26. A Standard Factory... srcclr.com | @srcclr ● Bare Metal Provisioning ● Configuration Management ● Remote Execution Framework
  • 29. As a framework it is: srcclr.com | @srcclr ● Hard to diagnose what is broken ● One part breaks, the entire thing breaks ● Unwieldy code bases ● Works for some, wasn’t for us
  • 30. The Monolith Factory srcclr.com | @srcclr ● Statically schedules services ● Doesn’t require service discovery
  • 32. As a framework it is: srcclr.com | @srcclr ● Atomic services ● Easy(er) to figure out what is broken ● Scale or add individual pieces
  • 33. The Micro-Services Factory srcclr.com | @srcclr ● Dynamic task scheduling ● Service discovery required
  • 34. The Scaling Problem... srcclr.com | @srcclr ● Service ‘x’ requires known port assignments ● Service ‘x’ configuration changes across env’s ● Service ‘x’ should be able to run on a box with other instances of Service ‘x’ as well as Service ‘y’ and Service ‘z’
  • 35. The Vertical Component srcclr.com | @srcclr ● Start locally, on a single box ● Find a solution that works vertically, master it ● Once the vertical solution is found, move horizontally
  • 36. Dynamic Task Scheduling srcclr.com | @srcclr ● Purpose built remote execution framework
  • 37. What we really need... srcclr.com | @srcclr ● Purpose built remote execution framework ● … micro services are like streakers…
  • 38. They don’t care where they’re running, they just want to be exposed. srcclr.com | @srcclr ● Dynamic tasks scheduling ● … micro services are like streaker`
  • 39. What we really need... srcclr.com | @srcclr ● Purpose built systems ● … CM does CM; SD does SD; divide and conquer
  • 40. Configuration Management srcclr.com | @srcclr ● Is still important! ● Is still necessary!
  • 41. srcclr.com | @srcclr Our Remote Execution Framework
  • 42. Our Initial Deployment srcclr.com | @srcclr ● Apache Mesos ● Marathon
  • 43. "Type" : "AWS::EC2::Instance", "Properties" : { "KeyName" : "secure", "SecurityGroupIds" : ["sg-1234abcd","sg-5678efg"], "SubnetId" : "subnet-1234abcd", "UserData" : { "Fn::Base64" : { "Fn::Join" : ["", [ "#!/bin/sh -vn", "ROLE='qa_nginx_static'n", "MASTER='https://puppet.srcclr.com'n", "D_ROLE=$(echo $ROLE | tr '_' '-')n", "D_IP=$(hostname -I | tr '.' '-' | cut -d' ' -f1)n", "HOSTNAME="$(echo $D_ROLE)-$(echo $D_IP)"n", "echo "127.0.0.1 $HOSTNAME" >> /etc/hosts", "apt-get updaten", "echo $HOSTNAME > /etc/hostnamen", "/bin/hostname $HOSTNAMEn", "echo $ROLE > /etc/rolen", "sudo curl -k $MASTER:8140/packages/current/install.bash | sudo bashn" ]]} Design Pattern : Bare Metal
  • 44. class roles::mesos_master { include ::profiles::mesos::basic include ::profiles::mesos::master include ::profiles::docker::marathon include ::profiles::haproxy::marathon_template } Design Pattern : Config Mgmt
  • 45. Design Pattern : Application Layer Mesos for Layer 7: - Deploy application layer via Docker - Ensure service ‘x’ is running ‘n’ number of times
  • 46. { "container": { "type": "DOCKER", "docker": { "forcePullImage": true, "image": "malnick/microbrew", Design Pattern : Service Discovery Marathon for Service Discovery/Deployment: - API to Apache Mesos - Queried for IP/Port assignments of layer 7 resources to configure haproxy
  • 47. LIVE DEMO Are you sure you want to do this? Pray to the demo gods
  • 48. Jeff Malnick Paul Ambrosini malnick at gmail dot com github.com/malnick @malnick technoblogic.io srcclr.com | @srcclr c at c4 dot vc paul at srcclr dot com github.com/cl4r1ty @cl4r1ty c4.vc