SlideShare a Scribd company logo
Cloudify 3 Workshop 
#ccceu 
Budapest 2014 
Uri Cohen - @uri1803
INTRODUCTION 
(OR WHY WE NEED THIS AT ALL…)
The World Is 
about 
Services & 
Apps
Automation Is 
Key for: 
• Testability 
• Consistency 
• Agility 
• Stability
The Automation Continuum 
Environment 
Creation 
SW Infra. 
Setup & 
Config 
Code Push Monitoring 
& Alarming 
Repairing Scaling
The Automation Continuum 
Environment 
Creation 
• VMs / Bare Metal Servers 
• Network (Firewall, NAT, VPN, etc.) 
• LB Groups 
• Storage (Block / Blob)
The Automation Continuum 
SW Infrastructure 
Setup & Configuration 
• OS Configuration (e.g. ulimit, useradd, permissions, etc.) 
• Installation of packages and middleware components 
• Startup orchestration 
• Update (not very frequent)
The Automation Continuum 
Code Push 
• User code installation on software infrastructure 
– e.g. jar, war, rails sources, PHP sources, DB scripts, etc. 
– After setup 
– On going - can be very frequent 
• Push policies (canary, red/black, a/b)
The Automation Continuum 
Monitoring 
& Alarming 
• What should be monitored? 
– Availability: are my services up or not? 
– Performance (OS &services level metrics). How are my services doing? 
– State: What’s running where, state of system resources (e.g. quota 
utilization) 
• Alarms upon failure or when reaching certain 
thresholds 
– Simple (a-la CloudWatch) or complex (CEP driven)
The Automation Continuum 
Repairing 
• Various types of failures 
– Service level – service not responding, process failed 
– VM / Node failure 
– Infrastructure failure (disk, network) 
• Automation tools can go a certain way 
– Resiliency should also be part of the SW stack
The Automation Continuum 
Scaling 
• Manually or Automatically (alarm triggered) 
• Scaling by 
– Adding / removing instances (AKA out / in) 
– Adding / removing resources to / from an existing instance (AKA up / 
down) 
• For both, it needs to be supported by the SW stack
Let’s Look at 
Some Tools
Orchestration Tools 
Environment 
Creation 
SW Infra. 
Setup & 
Config 
Code Push Monitoring 
& Alarming 
Repairing Scaling
CM Tools 
Environment 
Creation 
SW Infra. 
Setup & 
Config 
Code Push Monitoring 
& Alarming 
Repairing Scaling
Monitoring 
Environment 
Creation 
SW Infra. 
Setup & 
Config 
Code Push Monitoring 
& Alarming 
Repairing Scaling
Tying The 
Pieces 
Together 
Usually 
Looks Like 
This
A Way to tie all the pieces 
on the Automation 
Continuum together 
• Use what works best, 
not reinvent each piece 
from scratch
Open Source Platform 
for Deploying, Managing 
and Scaling Complex 
Multi-Tier Applications 
on the Cloud
So You Can Have This 
Environment 
Creation 
SW Infra. 
Setup & 
Config 
Code Push Monitoring 
& Alarming 
Repairing Scaling
Main Functions 
• Deployment modeling using TOSCA 
• Automated resource creation, placement, 
configuration and startup 
• Metric and log collection 
• Monitoring 
• Auto-repairing 
• Auto-scaling 
• Deployment updates (infra and app code)
Cloudify in the Devops Toolchain 
API 
Orchestration 
CI 
Monitoring 
& Alarming 
CM Infrastructure
Cloudify in the Devops Toolchain 
API 
Orchestration 
CI 
Monitoring 
& Alarming 
TOSCA 
CM Infrastructure
Architecture
Architecture
Architecture
Demo 1 
Setup up a Manager 
on CloudStack
CLOUDIFY 3 BLUEPRINTS – 
DOING IT THE TOSCA WAY
Cloudify 3 Blueprints 
• A Blueprint is an Orchestration Plan 
for a single* application 
• It has 3 parts: 
• Topology: Declarative written in YAML DSL 
• Workflows: Imperative written in Python* 
• Policies: Declarative, written mostly in YAML 
• Conforms to TOSCA (next slide)
What is TOSCA? 
• Topology & Orchestration Specification of 
Cloud Application 
• By OASIS – Sponsored by IBM, CA, RH, 
Huawei and others 
• The goal is to allow for a cross cloud, cross 
tools orchestration of applications on the 
Cloud 
• Status: 
• Version 1 approved (XML). 
• Version 2 (also YAML) – in design
TOSCA-Inspired Application Blueprints 
Application 
Topologies 
Workflows 
Policies
Why TOSCA? 
• Standard 
• Can Describe 
• Any Topology 
• Any Automation Process 
• Portable between Clouds and Tools
So here’s an application
What do we see here? 
Host 
Middleware 
App module 
connection
What Have We Seen? 
• An application topology 
• 3 levels of components: 
• Infrastructure (Cloud or DC objects) 
• Platform or Middleware (App containers) 
• Application modules, schemas and configurations 
• Relationships between components 
(dependencies): 
• What’s hosted on what or installed on what 
• What’s connected to what
What’s in TOSCA Topology? 
• Inputs and outputs 
• Types and nodes 
• Relationships 
• Requirements and capabilities
Input and Outputs 
• A way to parameterize blueprints 
and let them declare runtime 
computed values (URLs, passwords, 
etc.)
Inputs and Outputs 
inputs: 
cloudstack_api_url: 
default: '' 
type: string 
cloudstack_key: 
default: '' 
type: string 
cloudstack_secret: 
default: '' 
type: string 
... 
outputs: 
endpoint: 
description: Web application endpoint 
value: 
ip_address: { get_attribute: [ nodejs_vm, ip ] } 
port: { get_property: [ nodecellar_app, base_port ] }
Types & Nodes 
• Each component in the topology is a node: 
• For example, a VM is a node, a Webserver is a Node 
• The node holds the configuration (properties) and the relationships to 
other nodes 
• A node has a type 
• The type is where the lifecycle interface operations are defined 
• The type specified the properties schema 
• Default lifecycle operations are: 
• create 
• configure 
• start 
• stop 
• delete 
38
Type Example 
39 
Can be scripts or 
references to Python 
functions implemented 
by plugins
Relationships 
• There are 3 types of relationships: 
• depends_on – which is the base type 
• conataind_in – a component is hosted / contained / deployed 
within nother 
• connected_to – a component needs to establish a connection to 
another and therefore this needs to be configured 
• The relationship can define operation to be applied on the 
source of the target instances 
• Possible operations on each: 
• preconfigure – before node configure is called 
• postconfigure – after node configure is called but before start 
• establish – after start when connection needs to be established 
• unlink – remove the connection 
40
Relationship Example 
Can be scripts or 
references to Python 
functions implemented 
41 
by plugins
Requirements and Capabilities
One Way of Putting This 
Nodecellar_app 
IS CONNECTED to 
mongod
Another Way of Putting This 
Nodecellar_app 
NEEDS a database of type 
‘MongoDB’
Requirements and Capabilities 
• Relationships will soon be replaced by a more 
declarative model created by the latest TOSCA 
work draft 
• “This type needs a database connection” 
instead of 
“This node is connected to a node that 
happens to be a database” 
• Cloudify to follow once spec approved
Requirements and Capabilities 
• A node type declares a certain 
capability 
• Another type in a blueprint declares 
that it requires this capability 
• A node in a blueprint can also 
declare that it needs a capability
Requirements and Capabilities 
tosca.nodes.Database: 
derived_from: tosca.nodes.Root 
properties: 
db_user: 
type: string 
db_password: 
type: string 
db_port: 
type: integer 
db_name: 
type: string 
description: the logical name of the database 
capabilities: 
- database_endpoint: tosca.capabilities.DatabaseEndpoint 
node_templates: 
wordpress: 
type: tosca.nodes.WebApplication.WordPress 
requirements: 
- host: webserver 
- database_endpoint: mysql_database
A Word About Blueprint Portability 
• Cloudify blueprint support the notion of 
abstract types 
– Kind of like abstract classes in OOD 
• Blueprints can be composed of multiple 
files 
• To achieve portability: 
– Topologies should be defined using portable types 
– Concrete types are then wired at blueprint creation 
time 
• Kind of like dependency injection
Workflows 
• TOSCA 1.0 –Workflows (Plans) are in 
any WF language. 
– Strong preference for BPMN 2.0 
• TOSCA 2.0 – No change 
• Cloudify 3 take – Workflows are 
currently python based 
– Tinkering with a more declarative approach 
(OpenStack Mistral?)
Policies 
• Still not defined by TOSCA, under 
discussion 
• Cloudify 3 – YAML mostly, uses 
Riemann.io under the hood 
– You can create very sophisticated custom policies, 
in Clojure…
Putting it all together 
• TOSCA Template (Blueprint in 
Cloudify) contains: 
– Application Topology 
• Nodes 
– Interfaces and operations 
– Properties 
– Relationships 
– Workflows (install, uninstall, scale out, CD) 
– Policies (scale trigger, recovery trigger)
Demo 2 
Upload a blueprint 
and install it
WHAT REALLY HAPPENED HERE?
We Triggered a Few Processes 
• Blueprint and deployment creation 
• Workflow execution 
• Availability reporting 
• Log and metric collection
BLUEPRINT AND DEPLOYMENT 
CREATION
Blueprint Upload 
59 
Gunicorn 
Node 
ElasticSearch 
Cloudify Manager 
Nginx 
Blueprint saved in 
ElasticSearch
Deployment Creation 
60 
Gunicorn 
Node 
ElasticSearch 
Cloudify Manager 
Nginx 
Celery 
Worker 
Celery 
Workers 
Dedicated deployment 
workers created 
RabbitMQ
WORKFLOW EXECUTION
The Bigger Picture 
Agent 
CeleryD 
Worker 
Worker 
Worker 
Plugin 
RabbitMQ 
Tasks 
Logs 
Workflow 
Worker 
Logstash 
Elastic 
Search Runtime 
Properties 
Created Riemann
Workflow Execution
LOGS & EVENTS
Logs & Events Functionality 
• Cloudify components logs are 
gathered, indexed and persisted 
• Events give the user a simple and 
clear way to trace the progress of a 
workflow execution 
• Available from API, CLI and web GUI
Logs & Events Mechanism 
Source 
Component 
RabbitMQ Log Stash Elastic Search 
REST API 
Queued 
Formatted 
+ Piped 
Indexed + 
Persisted 
Queries
Closing the Feedback Loop 
Celery 
Collectd / 
Diamond 
RabbitMQ 
Application 
Stack 
Nagios 
Zabbix 
… 
Riemann 
Cloudify Manager 
Third party 
monitoring tool 
Metrics VM 
InfluxDB 
Logstash 
App VM
Policy Engine Work Model 
When handler 
function detects 
policy violation it 
emits an event that 
triggers a workflow 
1. User can define a 
selector to create a 
stream 
2. Apply rules for stream 
to decide about the 
output 
Monitoring tools 
send events to 
Riemann
Demo 3 Monitoring
If You Want 
to Dive 
Deeper 
• Plugins 
– IaaS: CloudStack, 
OpenStack, AWS 
(libcloud), vSphere, 
vCloud, SoftLayer 
– Chef, Puppet, Salt, 
Fabric, Docker 
– Role your own 
• Workflows 
• Policies
References 
• Cloudify home: getcloudify.org 
• Github: github.com/cloudify-cosmo 
• CloudStack integration (in the works): 
github.com/cloudify-cosmo/?query=cloudstack 
• TOSCA: 
https://www.oasis-open.org/committees/tosca/
Thank You!

More Related Content

PPTX
Introduction to devops
PDF
Scaling DevSecOps Culture for Enterprise
DOCX
Technology organizational chart
PDF
DevOps: A Culture Transformation, More than Technology
PPTX
DevOps.pptx
PDF
2019 DevSecOps Reference Architectures
PPTX
CI/CD Best Practices for Your DevOps Journey
PDF
Using the Open Source OPC-UA Client and Server for Your IIoT Solutions | Jero...
Introduction to devops
Scaling DevSecOps Culture for Enterprise
Technology organizational chart
DevOps: A Culture Transformation, More than Technology
DevOps.pptx
2019 DevSecOps Reference Architectures
CI/CD Best Practices for Your DevOps Journey
Using the Open Source OPC-UA Client and Server for Your IIoT Solutions | Jero...

Viewers also liked (13)

PPTX
Building hybrid cloud with cloudify (public)
PPTX
Alef event - going open source
PPT
Cloudify Open PaaS Stack for DevOps
PDF
Orchestrating Cloud Applications With TOSCA
PPTX
Real World Example of Orchestrating Docker, Node JS, NFV on OpenStack
PPTX
Introduction to Cloudify for OpenStack users
PPTX
Automating Cloud Orchestration with Puppet and Cloudify
PPTX
TOSCA and Cloudify
PPTX
Container Orchestration
PDF
Docker swarm introduction
PPTX
Orchestration Tool Roundup - Arthur Berezin & Trammell Scruggs
PDF
Heart of the SwarmKit: Store, Topology & Object Model
PPTX
Orchestration tool roundup kubernetes vs. docker vs. heat vs. terra form vs...
Building hybrid cloud with cloudify (public)
Alef event - going open source
Cloudify Open PaaS Stack for DevOps
Orchestrating Cloud Applications With TOSCA
Real World Example of Orchestrating Docker, Node JS, NFV on OpenStack
Introduction to Cloudify for OpenStack users
Automating Cloud Orchestration with Puppet and Cloudify
TOSCA and Cloudify
Container Orchestration
Docker swarm introduction
Orchestration Tool Roundup - Arthur Berezin & Trammell Scruggs
Heart of the SwarmKit: Store, Topology & Object Model
Orchestration tool roundup kubernetes vs. docker vs. heat vs. terra form vs...
Ad

Similar to Cloudify workshop at CCCEU 2014 (20)

PPTX
Enabling .NET Apps with Monitoring and Management Using Steeltoe
PDF
MuleSoft Surat Virtual Meetup#27 - MuleSoft Runtime 4.4, Transit Gateway and ...
PDF
Stay productive_while_slicing_up_the_monolith
PDF
Cloud APIs Overview Tucker
PPTX
Why NBC Universal Migrated to MongoDB Atlas
PDF
Externalized Distributed Configuration Management with Spring Cloud Config-Se...
PPTX
Integration Monday - BizTalk Migrator Deep Dive
PDF
Elements for an iOS Backend
PPTX
Using AWS To Build A Scalable Machine Data Analytics Service
PDF
Scaling security in a cloud environment v0.5 (Sep 2017)
PDF
Introduction-to-Cloud-Computing.pdf
PDF
PowerShell DSC - State of the Art & Community by Gael Colas
PDF
DevOps: Automate all the things
PDF
Build cloud native solution using open source
PPTX
What's New in Docker - February 2017
PPTX
Azure from scratch part 3 By Girish Kalamati
PDF
Open shift and docker - october,2014
PPTX
4 Anguadasdfasdasdfasdfsdfasdfaslar (1).pptx
PDF
Microservices for java architects it-symposium-2015-09-15
PPTX
Serverless: The future of application delivery
Enabling .NET Apps with Monitoring and Management Using Steeltoe
MuleSoft Surat Virtual Meetup#27 - MuleSoft Runtime 4.4, Transit Gateway and ...
Stay productive_while_slicing_up_the_monolith
Cloud APIs Overview Tucker
Why NBC Universal Migrated to MongoDB Atlas
Externalized Distributed Configuration Management with Spring Cloud Config-Se...
Integration Monday - BizTalk Migrator Deep Dive
Elements for an iOS Backend
Using AWS To Build A Scalable Machine Data Analytics Service
Scaling security in a cloud environment v0.5 (Sep 2017)
Introduction-to-Cloud-Computing.pdf
PowerShell DSC - State of the Art & Community by Gael Colas
DevOps: Automate all the things
Build cloud native solution using open source
What's New in Docker - February 2017
Azure from scratch part 3 By Girish Kalamati
Open shift and docker - october,2014
4 Anguadasdfasdasdfasdfsdfasdfaslar (1).pptx
Microservices for java architects it-symposium-2015-09-15
Serverless: The future of application delivery
Ad

More from Uri Cohen (20)

PPTX
Orchestration tool roundup - OpenStack Israel summit - kubernetes vs. docker...
PPTX
SSDs, IMDGs and All the Rest - Jax London
PPTX
GigaSpaces XAP for Financial Services
PPTX
In Memory Data Grids, Demystified!
PPTX
App Centric Devops - CloudStack 2014 Collaboration Conference #CCNA14
PPTX
Its the app stupid - CloudStack 2014 Collaboration Conference #CCNA14
PPTX
Deployment Automation on OpenStack with TOSCA and Cloudify
PPTX
Cloud stack collabiration conference - It's the app, stupid!
PPTX
Changing organizational culture - a sweaty usecase
PPTX
GigaSpaces XAP - Don't Call Me Cache!
PPTX
Oscon 2013 - Lessons from building an open source community
PPTX
Oscon 2013 -Your OSS Project Is now served
PPTX
OpenStack Israel Summit 2013 - It’s the App, Stupid!
PPTX
One Does Not Simply Walk Into Devops
PPTX
MongoDB in the Clouds
PPTX
Carrier Paas - CloudStack Collaboration Event 2012
PPTX
Your Apps on the Cloud - What it really takes
PPTX
Cassandra summit - Big Data Apps on the cloud
PPTX
Trade and Event Processing at a Massive Scale - QCon NY 2012
PPTX
DevOps Meets PaaS - NY Meetup with Chef (OpsCode)
Orchestration tool roundup - OpenStack Israel summit - kubernetes vs. docker...
SSDs, IMDGs and All the Rest - Jax London
GigaSpaces XAP for Financial Services
In Memory Data Grids, Demystified!
App Centric Devops - CloudStack 2014 Collaboration Conference #CCNA14
Its the app stupid - CloudStack 2014 Collaboration Conference #CCNA14
Deployment Automation on OpenStack with TOSCA and Cloudify
Cloud stack collabiration conference - It's the app, stupid!
Changing organizational culture - a sweaty usecase
GigaSpaces XAP - Don't Call Me Cache!
Oscon 2013 - Lessons from building an open source community
Oscon 2013 -Your OSS Project Is now served
OpenStack Israel Summit 2013 - It’s the App, Stupid!
One Does Not Simply Walk Into Devops
MongoDB in the Clouds
Carrier Paas - CloudStack Collaboration Event 2012
Your Apps on the Cloud - What it really takes
Cassandra summit - Big Data Apps on the cloud
Trade and Event Processing at a Massive Scale - QCon NY 2012
DevOps Meets PaaS - NY Meetup with Chef (OpsCode)

Recently uploaded (20)

PDF
CIFDAQ's Market Insight: SEC Turns Pro Crypto
PDF
Bridging biosciences and deep learning for revolutionary discoveries: a compr...
PDF
KodekX | Application Modernization Development
PDF
Network Security Unit 5.pdf for BCA BBA.
PPT
Teaching material agriculture food technology
PDF
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
PDF
NewMind AI Monthly Chronicles - July 2025
PDF
solutions_manual_-_materials___processing_in_manufacturing__demargo_.pdf
PDF
GamePlan Trading System Review: Professional Trader's Honest Take
PPTX
breach-and-attack-simulation-cybersecurity-india-chennai-defenderrabbit-2025....
PDF
Modernizing your data center with Dell and AMD
PPT
“AI and Expert System Decision Support & Business Intelligence Systems”
PPTX
Effective Security Operations Center (SOC) A Modern, Strategic, and Threat-In...
PDF
Reach Out and Touch Someone: Haptics and Empathic Computing
PDF
Chapter 3 Spatial Domain Image Processing.pdf
PPTX
VMware vSphere Foundation How to Sell Presentation-Ver1.4-2-14-2024.pptx
PDF
How UI/UX Design Impacts User Retention in Mobile Apps.pdf
PDF
Machine learning based COVID-19 study performance prediction
PDF
Shreyas Phanse Resume: Experienced Backend Engineer | Java • Spring Boot • Ka...
PDF
Diabetes mellitus diagnosis method based random forest with bat algorithm
CIFDAQ's Market Insight: SEC Turns Pro Crypto
Bridging biosciences and deep learning for revolutionary discoveries: a compr...
KodekX | Application Modernization Development
Network Security Unit 5.pdf for BCA BBA.
Teaching material agriculture food technology
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
NewMind AI Monthly Chronicles - July 2025
solutions_manual_-_materials___processing_in_manufacturing__demargo_.pdf
GamePlan Trading System Review: Professional Trader's Honest Take
breach-and-attack-simulation-cybersecurity-india-chennai-defenderrabbit-2025....
Modernizing your data center with Dell and AMD
“AI and Expert System Decision Support & Business Intelligence Systems”
Effective Security Operations Center (SOC) A Modern, Strategic, and Threat-In...
Reach Out and Touch Someone: Haptics and Empathic Computing
Chapter 3 Spatial Domain Image Processing.pdf
VMware vSphere Foundation How to Sell Presentation-Ver1.4-2-14-2024.pptx
How UI/UX Design Impacts User Retention in Mobile Apps.pdf
Machine learning based COVID-19 study performance prediction
Shreyas Phanse Resume: Experienced Backend Engineer | Java • Spring Boot • Ka...
Diabetes mellitus diagnosis method based random forest with bat algorithm

Cloudify workshop at CCCEU 2014

  • 1. Cloudify 3 Workshop #ccceu Budapest 2014 Uri Cohen - @uri1803
  • 2. INTRODUCTION (OR WHY WE NEED THIS AT ALL…)
  • 3. The World Is about Services & Apps
  • 4. Automation Is Key for: • Testability • Consistency • Agility • Stability
  • 5. The Automation Continuum Environment Creation SW Infra. Setup & Config Code Push Monitoring & Alarming Repairing Scaling
  • 6. The Automation Continuum Environment Creation • VMs / Bare Metal Servers • Network (Firewall, NAT, VPN, etc.) • LB Groups • Storage (Block / Blob)
  • 7. The Automation Continuum SW Infrastructure Setup & Configuration • OS Configuration (e.g. ulimit, useradd, permissions, etc.) • Installation of packages and middleware components • Startup orchestration • Update (not very frequent)
  • 8. The Automation Continuum Code Push • User code installation on software infrastructure – e.g. jar, war, rails sources, PHP sources, DB scripts, etc. – After setup – On going - can be very frequent • Push policies (canary, red/black, a/b)
  • 9. The Automation Continuum Monitoring & Alarming • What should be monitored? – Availability: are my services up or not? – Performance (OS &services level metrics). How are my services doing? – State: What’s running where, state of system resources (e.g. quota utilization) • Alarms upon failure or when reaching certain thresholds – Simple (a-la CloudWatch) or complex (CEP driven)
  • 10. The Automation Continuum Repairing • Various types of failures – Service level – service not responding, process failed – VM / Node failure – Infrastructure failure (disk, network) • Automation tools can go a certain way – Resiliency should also be part of the SW stack
  • 11. The Automation Continuum Scaling • Manually or Automatically (alarm triggered) • Scaling by – Adding / removing instances (AKA out / in) – Adding / removing resources to / from an existing instance (AKA up / down) • For both, it needs to be supported by the SW stack
  • 12. Let’s Look at Some Tools
  • 13. Orchestration Tools Environment Creation SW Infra. Setup & Config Code Push Monitoring & Alarming Repairing Scaling
  • 14. CM Tools Environment Creation SW Infra. Setup & Config Code Push Monitoring & Alarming Repairing Scaling
  • 15. Monitoring Environment Creation SW Infra. Setup & Config Code Push Monitoring & Alarming Repairing Scaling
  • 16. Tying The Pieces Together Usually Looks Like This
  • 17. A Way to tie all the pieces on the Automation Continuum together • Use what works best, not reinvent each piece from scratch
  • 18. Open Source Platform for Deploying, Managing and Scaling Complex Multi-Tier Applications on the Cloud
  • 19. So You Can Have This Environment Creation SW Infra. Setup & Config Code Push Monitoring & Alarming Repairing Scaling
  • 20. Main Functions • Deployment modeling using TOSCA • Automated resource creation, placement, configuration and startup • Metric and log collection • Monitoring • Auto-repairing • Auto-scaling • Deployment updates (infra and app code)
  • 21. Cloudify in the Devops Toolchain API Orchestration CI Monitoring & Alarming CM Infrastructure
  • 22. Cloudify in the Devops Toolchain API Orchestration CI Monitoring & Alarming TOSCA CM Infrastructure
  • 26. Demo 1 Setup up a Manager on CloudStack
  • 27. CLOUDIFY 3 BLUEPRINTS – DOING IT THE TOSCA WAY
  • 28. Cloudify 3 Blueprints • A Blueprint is an Orchestration Plan for a single* application • It has 3 parts: • Topology: Declarative written in YAML DSL • Workflows: Imperative written in Python* • Policies: Declarative, written mostly in YAML • Conforms to TOSCA (next slide)
  • 29. What is TOSCA? • Topology & Orchestration Specification of Cloud Application • By OASIS – Sponsored by IBM, CA, RH, Huawei and others • The goal is to allow for a cross cloud, cross tools orchestration of applications on the Cloud • Status: • Version 1 approved (XML). • Version 2 (also YAML) – in design
  • 30. TOSCA-Inspired Application Blueprints Application Topologies Workflows Policies
  • 31. Why TOSCA? • Standard • Can Describe • Any Topology • Any Automation Process • Portable between Clouds and Tools
  • 32. So here’s an application
  • 33. What do we see here? Host Middleware App module connection
  • 34. What Have We Seen? • An application topology • 3 levels of components: • Infrastructure (Cloud or DC objects) • Platform or Middleware (App containers) • Application modules, schemas and configurations • Relationships between components (dependencies): • What’s hosted on what or installed on what • What’s connected to what
  • 35. What’s in TOSCA Topology? • Inputs and outputs • Types and nodes • Relationships • Requirements and capabilities
  • 36. Input and Outputs • A way to parameterize blueprints and let them declare runtime computed values (URLs, passwords, etc.)
  • 37. Inputs and Outputs inputs: cloudstack_api_url: default: '' type: string cloudstack_key: default: '' type: string cloudstack_secret: default: '' type: string ... outputs: endpoint: description: Web application endpoint value: ip_address: { get_attribute: [ nodejs_vm, ip ] } port: { get_property: [ nodecellar_app, base_port ] }
  • 38. Types & Nodes • Each component in the topology is a node: • For example, a VM is a node, a Webserver is a Node • The node holds the configuration (properties) and the relationships to other nodes • A node has a type • The type is where the lifecycle interface operations are defined • The type specified the properties schema • Default lifecycle operations are: • create • configure • start • stop • delete 38
  • 39. Type Example 39 Can be scripts or references to Python functions implemented by plugins
  • 40. Relationships • There are 3 types of relationships: • depends_on – which is the base type • conataind_in – a component is hosted / contained / deployed within nother • connected_to – a component needs to establish a connection to another and therefore this needs to be configured • The relationship can define operation to be applied on the source of the target instances • Possible operations on each: • preconfigure – before node configure is called • postconfigure – after node configure is called but before start • establish – after start when connection needs to be established • unlink – remove the connection 40
  • 41. Relationship Example Can be scripts or references to Python functions implemented 41 by plugins
  • 43. One Way of Putting This Nodecellar_app IS CONNECTED to mongod
  • 44. Another Way of Putting This Nodecellar_app NEEDS a database of type ‘MongoDB’
  • 45. Requirements and Capabilities • Relationships will soon be replaced by a more declarative model created by the latest TOSCA work draft • “This type needs a database connection” instead of “This node is connected to a node that happens to be a database” • Cloudify to follow once spec approved
  • 46. Requirements and Capabilities • A node type declares a certain capability • Another type in a blueprint declares that it requires this capability • A node in a blueprint can also declare that it needs a capability
  • 47. Requirements and Capabilities tosca.nodes.Database: derived_from: tosca.nodes.Root properties: db_user: type: string db_password: type: string db_port: type: integer db_name: type: string description: the logical name of the database capabilities: - database_endpoint: tosca.capabilities.DatabaseEndpoint node_templates: wordpress: type: tosca.nodes.WebApplication.WordPress requirements: - host: webserver - database_endpoint: mysql_database
  • 48. A Word About Blueprint Portability • Cloudify blueprint support the notion of abstract types – Kind of like abstract classes in OOD • Blueprints can be composed of multiple files • To achieve portability: – Topologies should be defined using portable types – Concrete types are then wired at blueprint creation time • Kind of like dependency injection
  • 49. Workflows • TOSCA 1.0 –Workflows (Plans) are in any WF language. – Strong preference for BPMN 2.0 • TOSCA 2.0 – No change • Cloudify 3 take – Workflows are currently python based – Tinkering with a more declarative approach (OpenStack Mistral?)
  • 50. Policies • Still not defined by TOSCA, under discussion • Cloudify 3 – YAML mostly, uses Riemann.io under the hood – You can create very sophisticated custom policies, in Clojure…
  • 51. Putting it all together • TOSCA Template (Blueprint in Cloudify) contains: – Application Topology • Nodes – Interfaces and operations – Properties – Relationships – Workflows (install, uninstall, scale out, CD) – Policies (scale trigger, recovery trigger)
  • 52. Demo 2 Upload a blueprint and install it
  • 54. We Triggered a Few Processes • Blueprint and deployment creation • Workflow execution • Availability reporting • Log and metric collection
  • 56. Blueprint Upload 59 Gunicorn Node ElasticSearch Cloudify Manager Nginx Blueprint saved in ElasticSearch
  • 57. Deployment Creation 60 Gunicorn Node ElasticSearch Cloudify Manager Nginx Celery Worker Celery Workers Dedicated deployment workers created RabbitMQ
  • 59. The Bigger Picture Agent CeleryD Worker Worker Worker Plugin RabbitMQ Tasks Logs Workflow Worker Logstash Elastic Search Runtime Properties Created Riemann
  • 62. Logs & Events Functionality • Cloudify components logs are gathered, indexed and persisted • Events give the user a simple and clear way to trace the progress of a workflow execution • Available from API, CLI and web GUI
  • 63. Logs & Events Mechanism Source Component RabbitMQ Log Stash Elastic Search REST API Queued Formatted + Piped Indexed + Persisted Queries
  • 64. Closing the Feedback Loop Celery Collectd / Diamond RabbitMQ Application Stack Nagios Zabbix … Riemann Cloudify Manager Third party monitoring tool Metrics VM InfluxDB Logstash App VM
  • 65. Policy Engine Work Model When handler function detects policy violation it emits an event that triggers a workflow 1. User can define a selector to create a stream 2. Apply rules for stream to decide about the output Monitoring tools send events to Riemann
  • 67. If You Want to Dive Deeper • Plugins – IaaS: CloudStack, OpenStack, AWS (libcloud), vSphere, vCloud, SoftLayer – Chef, Puppet, Salt, Fabric, Docker – Role your own • Workflows • Policies
  • 68. References • Cloudify home: getcloudify.org • Github: github.com/cloudify-cosmo • CloudStack integration (in the works): github.com/cloudify-cosmo/?query=cloudstack • TOSCA: https://www.oasis-open.org/committees/tosca/

Editor's Notes

  • #14: Great at creating openstack resources, basic integration with Chef / puppet for sw config, basic built in monitoring and alarming, moving to ceilometer in Havana
  • #15: Env setup is not automated SW infra setup is good but has no startup orchestration
  • #16: Healthnmon is more geared toward cloud resource monitoring and is has more opinionated domain model, ceilometer seems to be picking momentum and
  • #18: Even AWS used Chef for this…
  • #19: Talk about what’s next
  • #22: Templates to describe and drive all these processes
  • #23: Templates to describe and drive all these processes