37
Potential Paths to using Liferay in the cloud Liferay West Coast Symposium, 2011 Harpreet Singh Senior Director, Product Management CloudBees ©2011 Cloud Bees, Inc. All Rights Reserved

How can Liferay Developers, Deployers move to the Cloud

Embed Size (px)

DESCRIPTION

T

Citation preview

Page 1: How can Liferay Developers, Deployers move to the Cloud

Potential Paths to using Liferay in the cloud

Liferay West Coast Symposium, 2011Harpreet SinghSenior Director, Product ManagementCloudBees

©2011 Cloud Bees, Inc. All Rights Reserved

Page 2: How can Liferay Developers, Deployers move to the Cloud

2

• I work for CloudBees– CloudBees is the top Platform-as-a-Service

company for Java• My background is

– in PaaS – development, deployment in the cloud– Jenkins Continuous Integration and – Java EE & Application Servers

• Invited here to speak about Jenkins and the cloud – topics that Liferay thinks would be very interesting & pertinent to Liferay developers

Who am I and What am I doing here?

©2011 CloudBees, Inc. All Rights Reserved

* Safe Harbor slide

Page 3: How can Liferay Developers, Deployers move to the Cloud

3©2011 Cloud Bees, Inc. All Rights Reserved

About CloudBees

The leading Platform as a Service (PaaS) for Java™

CloudBees services the complete lifecycle of Cloud application development and deployment.No Servers. No Virtual Machines. No IT.

Nectar – CloudBees pro version of Jenkins DEV@cloud – Cloud Services for Developers

We are the Jenkins experts Core service of DEV@cloud with

“Jenkins-as-a-Service” Kohsuke Kawaguchi part of the team

RUN@cloud – Frictionless runtime PaaS for Java apps

Page 4: How can Liferay Developers, Deployers move to the Cloud

4

Page 5: How can Liferay Developers, Deployers move to the Cloud

5

Our Position– Liferay developers/administrators should explore moving their

development and deployment to the cloud

What is the talk about?

©2011 CloudBees, Inc. All Rights Reserved

Your ActionPlugin developers

move plugin development to the cloud through services like CloudBees

Administratorsexplore moving your deployments to a PaaS today

ImplicationProductivity and Cost Benefits

Page 6: How can Liferay Developers, Deployers move to the Cloud

6

• What is the cloud?– IaaS/PaaS/SaaS– What does a PaaS bring?– PaaS solutions in the market

• Moving plugin development to the cloud

• Moving Liferay installation to the cloud

Agenda

©2011 CloudBees, Inc. All Rights Reserved

Page 7: How can Liferay Developers, Deployers move to the Cloud

What is the cloud?What is the cloud?

Show me the layered cakeShow me the layered cake

Page 8: How can Liferay Developers, Deployers move to the Cloud

8

Traditional Software Stack

Page 9: How can Liferay Developers, Deployers move to the Cloud

9

Outsourcing headaches

Cloud Provider

Page 10: How can Liferay Developers, Deployers move to the Cloud

10

3 Cloud Services Model: The layered Cake

Page 11: How can Liferay Developers, Deployers move to the Cloud

11

Cloud Service Provider ViewIaaS

Build Your Own StackBuild Your Own Stack

Manage stackManage stack

Build appBuild app

Manage appManage appConsumer ConcernConsumer Concern

Provider ConcernProvider Concern

PaaS

Pre-built PlatformPre-built Platform

Managed stackManaged stack

SaaS

Pre-built appPre-built app

Use AppUse App

Page 12: How can Liferay Developers, Deployers move to the Cloud

12

App Consumer View

Page 13: How can Liferay Developers, Deployers move to the Cloud

13

Isn't this hosting?

• You own resources– Pay for what you use

and not use

• No sharing• No elasticity

• Renting resources– Pay for what you use

• Sharing– Multi-tenant

• Elasticity

Hosting = Cloud =

Page 14: How can Liferay Developers, Deployers move to the Cloud

14

Page 15: How can Liferay Developers, Deployers move to the Cloud

15

ProvisioningProvisioning BillingBillingMonitoringMonitoringSLA PolicySLA Policy

Core Platform ServicesCore Platform Services

IaaSIaaS Virtualization/OSVirtualization/OS

MeteringMetering

App ServerApp Server MailMailLoggingLoggingDBMS/NoSQLDBMS/NoSQL

Middleware ServicesMiddleware Services

MessagingMessaging

Auto ScalingAuto Scaling CICIHAHA

Runtime ServicesRuntime Services

SCMSCM

ALM ServicesALM Services

PaaS: Services that you care about

UIUI IDEIDE

Dev ServicesDev Services

SDKSDK APIsAPIs

Page 16: How can Liferay Developers, Deployers move to the Cloud

16

PaaS LandscapeFlexibility Compatibility

SaaS-likeIaaS-like

OS Flex is server-centric

OS Flex is server-centric

Basic orchestration of AWS blocks

Basic orchestration of AWS blocks

.Net-on-a-Server, with only …

more constraints

.Net-on-a-Server, with only …

more constraints

Spring-centric offering, focused

on vCloud

Spring-centric offering, focused

on vCloud

JVM-based offering fully

server-agnostic

JVM-based offering fully

server-agnostic

Oldest SaaS-like offering but with

lots of env. constraints

Oldest SaaS-like offering but with

lots of env. constraints

Page 17: How can Liferay Developers, Deployers move to the Cloud

17

• What is the cloud?• Moving plugin development to the cloud

– Why CI? Why Jenkins?– Dev-to-deploy lifecycle today & tomorrow– Where does cloud help?– CloudBees: Jenkins in the cloud?

• Moving Liferay installation to the cloud

Agenda

©2011 CloudBees, Inc. All Rights Reserved

Page 18: How can Liferay Developers, Deployers move to the Cloud

Moving development to the Moving development to the cloudcloudCode, Build, Test in the cloudCode, Build, Test in the cloud

©2011 CloudBees, Inc. All Rights Reserved

Page 19: How can Liferay Developers, Deployers move to the Cloud

19

• Why?– Teams are increasingly distributed

• Being on the same page is a problem

– Maintaining a repo requires • Administrative skills• Repo machines

• Suggestions– Github: watch projects, follow colleagues– CloudBees forge: development, ci and

build in one place• Maven repositories in the cloud as well

Moving code to the cloud

©2011 CloudBees, Inc. All Rights Reserved

Page 20: How can Liferay Developers, Deployers move to the Cloud

20©2011 CloudBees, Inc. All Rights Reserved

Coding in the CloudGitHub & CloudBees

Page 21: How can Liferay Developers, Deployers move to the Cloud

21

What is CI?

©2011 CloudBees, Inc. All Rights Reserved

The ProblemThe Problem The SolutionThe Solution

• Traditional Development• Infrequent commits• Ad-hoc testing• Difficult integration

process• Infrequent releases• Testing @ end

• Leads to• Inefficient testing• Long, difficult, error-

prone integration• Low visibility on

development• Harder to fix issues

• Development with CI• frequent commits• Dedicated build server• Automatic builds• Automatic tests• Automatic reporting• Regular testing• Regular releases• Continuous deployment• Less bugs

• Core best practice in modern s/w development

Page 22: How can Liferay Developers, Deployers move to the Cloud

22

Principal Components of CI

©2011 CloudBees, Inc. All Rights Reserved

Page 23: How can Liferay Developers, Deployers move to the Cloud

23

What is Jenkins?

©2011 CloudBees, Inc. All Rights Reserved

AboutAbout

• History• Kohsuke starts Hudson @Sun• Hudson 1.0 as part of GlassFish• Oracle acquires Sun• Community moves away from Oracle• Thriving Jenkins community today

• Releases: Weekly, LTS• Adoption

• 25k+ sites using Jenkins• YHOO, RHAT, GS…

PluginsPlugins

• Extensible Architecture• 500+ plugins• Categories

• SCM• Subversion, CVS, Git…

• Build Tools• Gradle, Groovy, Promoted

builds, • Build Wrappers

• Selenium, Artifactory, AWS• Build Notifiers

• IRC, Jabber, Lavalamp• Build Reports

• Clover, Emma, PMD, Sonar…• …

#1 OSS Continuous Integration Server

Page 24: How can Liferay Developers, Deployers move to the Cloud

24©2011 CloudBees, Inc. All Rights Reserved

CI on your server

CI on the Cloud

Page 25: How can Liferay Developers, Deployers move to the Cloud

25

• Move code to the cloud• Setup Jenkins online

– Install SDK as part of build process• Code commit hooks

– Builds code automatically– Runs your tests– Runs code coverage – Runs cross browser tests

• Setup Liferay online– Deploy to Liferay instance

What does it mean for plugin developers?

©2011 CloudBees, Inc. All Rights Reserved

Page 26: How can Liferay Developers, Deployers move to the Cloud

Deploying Liferay to the Deploying Liferay to the cloudcloud

Page 27: How can Liferay Developers, Deployers move to the Cloud

27

Manage Application EnvironmentManage Application EnvironmentManage CI EnvironmentManage CI Environment

Manage Server Environment

What deployment should be?

Configure OSConfigure OS Secure OSSecure OS Setup JVMSetup JVM

Install AS on OS

Install AS on OS Configure ASConfigure AS Secure ASSecure AS

provision nodes

provision nodes

Install load-balancer (LB)Install load-

balancer (LB) Configure LBConfigure LB

Secure LBSecure LB Setup BC for cluster

Setup BC for cluster QA clusterQA cluster

Configure DNS

Configure DNS

Provision node:

Provision cluster:

Provision node

Provision node Install DBInstall DB Configure DBConfigure DB

Secure DBSecure DB Setup BC for DB

Setup BC for DB

Provision DB:

Provision cluster

Provision cluster Provision DBProvision DB Deploy

schemaDeploy schema

Deploy App to each node

Deploy App to each node

Deploy App:

(not a transparent update process)(not a transparent update process)

Analyse sec. bulletins

Analyse sec. bulletins

Analyse QA bulletins

Analyse QA bulletins

Analyse AS/OS logs

Analyse AS/OS logs

maintain OSmaintain OS maintain JVMmaintain JVM maintain ASmaintain AS

maintain DBmaintain DB

Manage environment (recurring)

maintain FWmaintain FW Validate/QA stack

Validate/QA stack

Measure App performanceMeasure App performance

Acquire HardwareAcquire

HardwareProvision

nodeProvision

node

Update ClusterUpdate Cluster Update LBUpdate LB

Metering/Scaling (recurring)

Update SecurityUpdate Security

Install PluginsInstall Plugins Manage PluginsManage PluginsApply

PatchesApply

Patches

Manage CI Environment:

Setup Master Setup Master Setup SlavesSetup Slaves

Setup CI Environment

DeployDeployBuildBuildContinuous Deployment

Page 28: How can Liferay Developers, Deployers move to the Cloud

28

Cloud Management / Virtualization / OSCloud Management / Virtualization / OS

©2011 CloudBees, Inc. All Rights Reserved

CloudBees Platform as a Service

Continuous Deployme

nt

Continuous Deployme

ntProductionProduction

BuildBuild

TestTest

ProvisioningProvisioning

Maintenance

Elasticity/HA

Maintenance

Elasticity/HA

JenkinsJenkinsJVM – Java EE

Java, Python, Scala, …

JVM – Java EEJava, Python, Scala,

CloudBees Core Platform ServicesCloudBees Core Platform Services

RUNRUNDEVDEV

RepositoriesRepositories

Data ServicesRDBMS, NoSQLData ServicesRDBMS, NoSQL

MeteringBilling

MeteringBillingMonitoringMonitoringManagementManagement

MessagingMessaging IdentityIdentity Logging/AuditingLogging/Auditing

Back-end servicesBack-end services

Runtime servicesRuntime services

GITGIT MavenMaven ……SVNSVN

APIsWeb UI, CLI, HTTP API, Eclipse, Maven, Ant, etc.

APIsWeb UI, CLI, HTTP API, Eclipse, Maven, Ant, etc.

DatabasesDatabases

Other SaaSOther SaaS

On Premise

On Premise

Page 29: How can Liferay Developers, Deployers move to the Cloud

29©2011 CloudBees, Inc. All Rights Reserved

Page 30: How can Liferay Developers, Deployers move to the Cloud

30

• Why deploy in the cloud?– Outsource to PaaS provider – no more

maintenance headaches– Start out quickly – up and running very

very quickly – great for POC’s– Plugin developers -> deploy -> to their

own instances, bring them and down once testing is done

– Scale up and down

Deploying Liferay in the cloud: Today

©2011 CloudBees, Inc. All Rights Reserved

Page 31: How can Liferay Developers, Deployers move to the Cloud

31

• Create a new database• Repackage standalone war

– Bundle libs into war instead of dropping in Tomcat directory

– Edit portal-ext.properties to add database information

• Choose medium plan on CloudBees• Download CloudBees SDK• Deploy application

– bees app:deploy• Detailed Steps: http://bit.ly/pca8Qc• Steps for Amzn Beanstalk (James Falkner’s

blog):– http://bit.ly/kwyIif

Steps to deploy Liferay to CloudBees

©2011 CloudBees, Inc. All Rights Reserved

Page 32: How can Liferay Developers, Deployers move to the Cloud

Liferay on CloudBeesLiferay on CloudBees

How does this look?How does this look?

©2011 CloudBees, Inc. All Rights Reserved

Page 33: How can Liferay Developers, Deployers move to the Cloud

33©2011 CloudBees, Inc. All Rights Reserved

Page 34: How can Liferay Developers, Deployers move to the Cloud

34

• Delivered through Liferay– liferaySaaS.com– Choose a plan: starter/medium/heavy

• Auto-migrate from starter->heavy based on traffic

• Liferay SaaS administrators handle the underlying migration magic for you

• Delivered through 3rd party (say CloudBees)– Liferay as an ecosystem provider– You get to choose amongst PaaS services

Liferay as a SaaS Application: Tomorrow

©2011 CloudBees, Inc. All Rights Reserved

Page 35: How can Liferay Developers, Deployers move to the Cloud

35©2011 CloudBees, Inc. All Rights Reserved

Page 36: How can Liferay Developers, Deployers move to the Cloud

36

Our Position– Liferay developers/administrators should explore moving their

development and deployment to the cloud

Conclusion

©2011 CloudBees, Inc. All Rights Reserved

Your ActionPlugin developers

move plugin development to the cloud through services like CloudBees

Administratorsexplore moving your deployments to a cloud today

ImplicationProductivity and Cost Benefits

Page 37: How can Liferay Developers, Deployers move to the Cloud

37