play with cloud foundry an open paas shi, tao may 11, 2012
TRANSCRIPT
![Page 1: Play with Cloud Foundry An Open PaaS Shi, Tao May 11, 2012](https://reader030.vdocuments.us/reader030/viewer/2022032604/56649e605503460f94b5bbdf/html5/thumbnails/1.jpg)
Play with Cloud FoundryAn Open PaaS
Shi, Tao
May 11, 2012
![Page 2: Play with Cloud Foundry An Open PaaS Shi, Tao May 11, 2012](https://reader030.vdocuments.us/reader030/viewer/2022032604/56649e605503460f94b5bbdf/html5/thumbnails/2.jpg)
• Overview
• Development Guide
• Deployment Guide
• Resource
• Q&A
Agenda
![Page 3: Play with Cloud Foundry An Open PaaS Shi, Tao May 11, 2012](https://reader030.vdocuments.us/reader030/viewer/2022032604/56649e605503460f94b5bbdf/html5/thumbnails/3.jpg)
Cloud Foundry Overview
• What’s Cloud Foundry?
• Languages/Frameworks
• Inner Service
• Logic View
• Architecture
• Disadvantages
![Page 4: Play with Cloud Foundry An Open PaaS Shi, Tao May 11, 2012](https://reader030.vdocuments.us/reader030/viewer/2022032604/56649e605503460f94b5bbdf/html5/thumbnails/4.jpg)
Type Vendor
SaaS
PaaS
IaaS
Cloud Computing System
![Page 5: Play with Cloud Foundry An Open PaaS Shi, Tao May 11, 2012](https://reader030.vdocuments.us/reader030/viewer/2022032604/56649e605503460f94b5bbdf/html5/thumbnails/5.jpg)
What’s Cloud Foundry?An open platform-as-a-service (PaaS). The system supports multiple frameworks, multiple application infrastructure services and deployment to multiple clouds.
![Page 6: Play with Cloud Foundry An Open PaaS Shi, Tao May 11, 2012](https://reader030.vdocuments.us/reader030/viewer/2022032604/56649e605503460f94b5bbdf/html5/thumbnails/6.jpg)
Languages/Frameworks/Service
Multi-LanguageRuby, Java, Scala, Node.js, Erlang, Python, PHP..
Multi-FrameworkRails, Sinatra, Spring, Grails, Express, Lift
Multi-ServicesMySQL, Postgres, MongoDB, Redis, RabbitMQ
Multi-Cloud, Multi-IaaSPublic Cloud, MicroCloud, Private Cloud
![Page 7: Play with Cloud Foundry An Open PaaS Shi, Tao May 11, 2012](https://reader030.vdocuments.us/reader030/viewer/2022032604/56649e605503460f94b5bbdf/html5/thumbnails/7.jpg)
Logic View
Router
Infrastructure
Health Manager
DEA: execution environmentServices: core, ecosystem, etc.
user appsCloud Controller user apps
vmc client STS plugin browser(user app access)
![Page 8: Play with Cloud Foundry An Open PaaS Shi, Tao May 11, 2012](https://reader030.vdocuments.us/reader030/viewer/2022032604/56649e605503460f94b5bbdf/html5/thumbnails/8.jpg)
Architecture
![Page 9: Play with Cloud Foundry An Open PaaS Shi, Tao May 11, 2012](https://reader030.vdocuments.us/reader030/viewer/2022032604/56649e605503460f94b5bbdf/html5/thumbnails/9.jpg)
Disadvantages
• Limited Services
• Limited File Generate/Access
• Charge Public Cloud
• No Infrastructure in China
• Beta
![Page 10: Play with Cloud Foundry An Open PaaS Shi, Tao May 11, 2012](https://reader030.vdocuments.us/reader030/viewer/2022032604/56649e605503460f94b5bbdf/html5/thumbnails/10.jpg)
• Overview
• Development Guide
• Deployment Guide
• Resource
• Q&A
Agenda
![Page 11: Play with Cloud Foundry An Open PaaS Shi, Tao May 11, 2012](https://reader030.vdocuments.us/reader030/viewer/2022032604/56649e605503460f94b5bbdf/html5/thumbnails/11.jpg)
Prepare
• Register
• Install Ruby and RubyGems
• Install VMC (VMware Cloud
Client)
• Install STS (with Cloud
Foundry Plugin)
![Page 12: Play with Cloud Foundry An Open PaaS Shi, Tao May 11, 2012](https://reader030.vdocuments.us/reader030/viewer/2022032604/56649e605503460f94b5bbdf/html5/thumbnails/12.jpg)
Spring to Cloud Foundry
• Auto Reconfiguration
• Cloud Namespace
• Spring 3.1 Profiles
![Page 13: Play with Cloud Foundry An Open PaaS Shi, Tao May 11, 2012](https://reader030.vdocuments.us/reader030/viewer/2022032604/56649e605503460f94b5bbdf/html5/thumbnails/13.jpg)
Auto Reconfiguration
Two modifications
1. Additional Jar
2. Update Web.xml
BeanFactoryPostProcessor
Examines the application context before
creating beans
Swaps existing beans of matching types
![Page 14: Play with Cloud Foundry An Open PaaS Shi, Tao May 11, 2012](https://reader030.vdocuments.us/reader030/viewer/2022032604/56649e605503460f94b5bbdf/html5/thumbnails/14.jpg)
Auto Reconfiguration
![Page 15: Play with Cloud Foundry An Open PaaS Shi, Tao May 11, 2012](https://reader030.vdocuments.us/reader030/viewer/2022032604/56649e605503460f94b5bbdf/html5/thumbnails/15.jpg)
Cloud App Setup
Maven
Spring Application-Context
![Page 16: Play with Cloud Foundry An Open PaaS Shi, Tao May 11, 2012](https://reader030.vdocuments.us/reader030/viewer/2022032604/56649e605503460f94b5bbdf/html5/thumbnails/16.jpg)
Cloud Namespace
Support Data Source
Other Support
![Page 17: Play with Cloud Foundry An Open PaaS Shi, Tao May 11, 2012](https://reader030.vdocuments.us/reader030/viewer/2022032604/56649e605503460f94b5bbdf/html5/thumbnails/17.jpg)
Spring 3.1 Profiles V3.1 adds new support for environments Stand-alone Containers
![Page 18: Play with Cloud Foundry An Open PaaS Shi, Tao May 11, 2012](https://reader030.vdocuments.us/reader030/viewer/2022032604/56649e605503460f94b5bbdf/html5/thumbnails/18.jpg)
Cloud Foundry / Public Cloud
Demo: Crawler
Http://www.somesite.com
Crawler
RibbitMQ Instance
Input url
WebApp
ConsumingImage Object
Crawler.cloudfoundry.com
MongoDBPersist
Query
Get urlDom parse
Produce Image Object
![Page 19: Play with Cloud Foundry An Open PaaS Shi, Tao May 11, 2012](https://reader030.vdocuments.us/reader030/viewer/2022032604/56649e605503460f94b5bbdf/html5/thumbnails/19.jpg)
Crawler WebApp
ImageUnitRepository ImageUnitGateway
MongoDB RabbitMQ
Crawler.war
Cloud Foundry Services
![Page 20: Play with Cloud Foundry An Open PaaS Shi, Tao May 11, 2012](https://reader030.vdocuments.us/reader030/viewer/2022032604/56649e605503460f94b5bbdf/html5/thumbnails/20.jpg)
• Overview
• Development Guide
• Deployment Guide
• Resource
• Q&A
Agenda
![Page 21: Play with Cloud Foundry An Open PaaS Shi, Tao May 11, 2012](https://reader030.vdocuments.us/reader030/viewer/2022032604/56649e605503460f94b5bbdf/html5/thumbnails/21.jpg)
Deployment Guide
• Deploy App
• Update App
• Binding Service to App
• Start/Stop App
• Scale App
![Page 22: Play with Cloud Foundry An Open PaaS Shi, Tao May 11, 2012](https://reader030.vdocuments.us/reader030/viewer/2022032604/56649e605503460f94b5bbdf/html5/thumbnails/22.jpg)
Deploy App
• vmc login• vmc target• vmc push• vmc update• vmc create-service• vmc bind-service
Via STSVia VMC
![Page 23: Play with Cloud Foundry An Open PaaS Shi, Tao May 11, 2012](https://reader030.vdocuments.us/reader030/viewer/2022032604/56649e605503460f94b5bbdf/html5/thumbnails/23.jpg)
Access Service
• TCP over HTTP tunnel
• Local client
• Remote server
• gem install caldecott
• vmc tunnel your-service
• Mongodb/mysql command Caldecott
![Page 24: Play with Cloud Foundry An Open PaaS Shi, Tao May 11, 2012](https://reader030.vdocuments.us/reader030/viewer/2022032604/56649e605503460f94b5bbdf/html5/thumbnails/24.jpg)
Micro Cloud Foundry(BETA)
A cloud packaged as a VMware Virtual MachineUse as a developer sandbox
• Use the services from Junit integration tests
• Deploy your application for functional testing
• Remote debugging from STS
![Page 25: Play with Cloud Foundry An Open PaaS Shi, Tao May 11, 2012](https://reader030.vdocuments.us/reader030/viewer/2022032604/56649e605503460f94b5bbdf/html5/thumbnails/25.jpg)
Micro Cloud Foundry Pre-requisites
Minimum 1 GB
RAM
Resources
Virtualization
Clients
Minimum 8 GB
Disk
Internet Connectivity
(w/DHCP is ideal)
VMC STS
![Page 26: Play with Cloud Foundry An Open PaaS Shi, Tao May 11, 2012](https://reader030.vdocuments.us/reader030/viewer/2022032604/56649e605503460f94b5bbdf/html5/thumbnails/26.jpg)
Download code Setup EnvironmentDeploy Behind
FirewallSetup Scripts
Apache2 license
Private CloudCloudFoundry.ORG
Your Infrastructure
![Page 27: Play with Cloud Foundry An Open PaaS Shi, Tao May 11, 2012](https://reader030.vdocuments.us/reader030/viewer/2022032604/56649e605503460f94b5bbdf/html5/thumbnails/27.jpg)
• Overview
• Development Guide
• Deployment Guide
• Resource
• Q&A
Agenda
![Page 28: Play with Cloud Foundry An Open PaaS Shi, Tao May 11, 2012](https://reader030.vdocuments.us/reader030/viewer/2022032604/56649e605503460f94b5bbdf/html5/thumbnails/28.jpg)
Things to Forget
• First normal form
• Waterfall model
• Single server deployment
• Single language skill
• Build everything from scratch
• Build custom infrastructure
![Page 29: Play with Cloud Foundry An Open PaaS Shi, Tao May 11, 2012](https://reader030.vdocuments.us/reader030/viewer/2022032604/56649e605503460f94b5bbdf/html5/thumbnails/29.jpg)
Things to Learn• Agile, API Design• UI Design, Javacript, HTML5, CSS3• A/B Testing• Open Source, Open Standards• Architecture, Distributed Computing • Cloud Platforms and APIs• Multiple types of languages (imperative, object, functional, logic)• Ability to encapsulate domain knowledge in a DSL• Build on the shoulders of giants: reuse, rest APIs• Pick your battles, choose what you need to build yourself to add
value• Learn to live in a box (embrace platform limitations) to think
outside the box• Use an App Store for distribution
![Page 30: Play with Cloud Foundry An Open PaaS Shi, Tao May 11, 2012](https://reader030.vdocuments.us/reader030/viewer/2022032604/56649e605503460f94b5bbdf/html5/thumbnails/30.jpg)
• Primary Site : cloudfoundry.com• Open Source Site : cloudfoundry.org• Twitter : @cloudfoundry• Blog : blog.cloudfoundry.com• FB : facebook.com/cloudfoundry• Support : support.cloudfoundry.com
Cloud Foundry Resources
![Page 31: Play with Cloud Foundry An Open PaaS Shi, Tao May 11, 2012](https://reader030.vdocuments.us/reader030/viewer/2022032604/56649e605503460f94b5bbdf/html5/thumbnails/31.jpg)
Q & A