summer school - building a cloud-aware application

Post on 21-Nov-2014

1.539 Views

Category:

Technology

0 Downloads

Preview:

Click to see full reader

DESCRIPTION

 

TRANSCRIPT

Build a Cloud Aware Application

Chris Haddad

Selvaratnam Uthaiyashankar

Read more about PaaS at http://blog.cobia.net/cobiacomm

Try StratosLive https://stratoslive.wso2.com/

Platform as a Service Criteria

• When to create Cloud aware applications?

• Cloud application use cases and patterns

• Architectural difference between web applications and cloud applications

• Cloud Aware Application Demo

• Key Metrics and Quick Start Use Cases

When to make applications Cloud Aware?

• Deliver application to massive consumer base (e.g. Twitter, Google, Pinterest, FaceBook)

• Services distributed across multiple providers • Infrastructure cost optimization strategy • Application resiliency improvement strategy • Create an ecosystem platform supporting cross-

partner digital business

Resource Tier

Cloud Scale and Distributed Providers

Functional Role

Client Tier

Integration Services

Integration Services Resource Services

Functional Role

Presentation and Mashups

Functional Role

Functional code

Presentation Role

Presentation and Mashups

Presentation and Mashups

Resource Services

Private Applications

Public Cloud Services

Business Proces

Business Process

Business Process Business Process and

Business Rules

Application Resiliency and Composition

Mobile Application

Application Portfolio

Hybrid Platform Services

Presentation Services

Resources Services

Functional Services

Business Process and

Rules Services

Integration Services

Composite Application

Business Service Portfolio

Integration Services

Cloud API

Endpoint

Infrastructure as a Service (IaaS)

SaaS Application

Web application Endpoint

Domain Specific Platform as a Service Delivering Cross-Partner Digital Business Platform

Vertical Application 3 M

an

ag

ed

by P

aa

S

Ve

rtica

l

Su

mm

it

OS/Hypervisor

Containers

Hardware

Programming Languages

Frameworks

App Source Code

App Data

Ve

rtica

l

AP

I

Domain Services

Domain Artifacts

App

Configuration

Domain Services

Domain Artifacts

App Source Code

App Data

App

Configuration

App Source Code

App Data

App

Configuration

Vertical Application 1 Vertical Application 2

Application Architecture Crossroads

Innovation

Familiarity

Cloud Application Patterns and Anti-Patterns

18

Deterministic performance

Deploy and execute on optimum topology

Separation of concerns

Embarrassingly Parallel / Shared Nothing ArchitectureMinimal

Consumption

Failure Resilient Leaky interfaces

Tightly coupled modules

Monolithic footprint

Single threaded, serial execution

Resource locks Single tenancy model

Cloud Aware Application Use Cases and Underlying Cloud Patterns

• Maximize utilization – Requires deterministic performance – Load balance based on tenant, service, and workload,

context

• Increase reliability, availability, scalability – Shared nothing architecture – Stateless server-side elements – Consensus protocols

• Ecosystem platform – Monetize assets based on business value – Tenant/Consumer personalization and isolation – Sharing domain specific business capabilities

Architectural Difference Between Web Application and Cloud Application

Web Application • Synchronous request-reply

interaction • Centralized state (i.e. single

database) and session management

• Clustered server instances • Silo architecture

Cloud Application • Asynchronous interaction • Queues and workers • Scale out across datacenters

and providers • Distributed state and session

management • Autonomous service instances • Tenant context personalization • Shared JVM / Shared Schema • Shared nothing architecture

Cloud Architecture Best Practices

Transitioning to a New normal – Traditional practices may not apply • Distributed and federated interactions

– Event based, heterogeneous systems, network latency

• Configurable containers and engines – Declarative data, rules, and process definitions

• De-normalized and simplified data models – Hadoop/BigTable, Hypertext media, simple NoSQL entities

• Expect failure – Systems span transactional control

• Applications decomposed into distinct services – Federated environment drives autonomy, statelessness, and

composition

Cloud Application Platform Shared Middleware Services

PaaS Evaluation Framework

• Cloud Characteristics

• Cloud Dimensions

• Production Ready

• DevOps Activities and Phases

• Cloud Architecture

• Platform Services

• Programming Model

PaaS Evaluation Framework

Cloud Architecture

• Tenancy, dynamic discovery, and distributed cache

• Fine-grained metering, billing, and reporting of business entities, activities, and interactions

• Scale discrete application service instances instead of scaling monolithic application instances

• Shared nothing architecture, Thirteen Dwarf Patterns, parallel processing, resource coordination

• Cloud service provisioning and load balancer

PaaS Evaluation Framework Platform Services • Presentation services • Application and service container services • Business process and business rule services • Integration services and message brokers • Composite application services (i.e. mashups and orchestration) • Complex event processing services • Data access and persistence services • Development governance • Application life-cycle management • Automated run-time governance services • Policy registry and repository services • Identity management • Security • Service level management • Compute, network, and storage infrastructure services

PaaS Evaluation Framework

Programming Model • Actor model (i.e. message passing instead of function

invocation • RESTful interactions • Dynamic recoverability • Consensus protocols • Asynchronous rather than synchronous interactions • Shared nothing architecture • Data partitioning and sharding • Federated data queries • Service orchestration • Functional programming • MapReduce

Cloud Application Demo • Register a new tenant

– Show the self service aspect, multi tenancy aspect

– Create and provision a new tenant on shared infrastructure

• Demonstrate PaaS facilities available for a tenant (metering, billing, logs)

• Upload an existing web application to the tenant

– Demonstrate the zero cost/easy migration of applications

• Creating a new hello world web application

– Demonstrate the procedure to create an application

– Deploy application to Cloud using WSO2 Dveloper Studio

• Secure the web application(Tie the authentication to underlying user model).

• Create a database

– Relational storage model options

– NoSQL storage model options

• Access a database via web application

• Expose a database table as data services.

• Demonstrate WSO2 Stratos and WSO2 StratosLive application platform services

• Explain the programming model + services

– Access "CarbonContext” within applications

Key Metrics

• Foundation • Time to create new application environment

• Time to redeploy application

• Optimize • Minimum and maximum scale

• Scale frequency (i.e. time to scale up/down)

• Transformation • Time and effort required integrating business process, event

processor – creating a complex app.

• Time and effort required to apply policy across tenant(s)

• Cost to operate application per user or transaction

Quick Start Use Cases

• DevOps Tooling and On-demand self-service

• Automated Governance

• Service level management and elastic scale

• Consumption based pricing and billing

Quick Start Use Cases

DevOps Tooling and On-demand self-service • Use Cases

– Rapidly provision application environment – Rapidly provision application tenant – Allocate, provision, monitor, manage, and administer

resources across multiple tenants, nodes, and locations

– Develop complex, composite integrated applications

• Key metrics – Time to create new application environment – Time to redeploy application

Quick Start Use Cases

Automated Governance • Use Cases

– Create users and configure rights – Deploy on preferred topology that meets deterministic

performance requirements (e.g., replication, utilization, latency, bandwidth, and coherency)

– Create service throttling and security governance (XACML) policies

• Key Metrics – Time and effort required integrating business process,

event processor – creating a complex app. – Time and effort required to apply policy across tenant(s)

Quick Start Use Cases

Service level management and elastic scale • Use cases

– Ensure application satisfies consumer demand while maximizing resource utilization • Scale workload processing and increase performance while

minimizing infrastructure spend

– Load test application service – Demonstrate multi-tenant web application

• Key Metrics – Minimum and maximum scale – Scale frequency (i.e. time to scale up/down)

Quick Start Use Cases

Consumption based pricing and billing

• Use cases

– View service logs

– View bill by business value

• Key Metric

– Cost to operate application per user or transaction

Contact us:

http://wso2.com/contact/

Follow us:

http://twitter.com/#!/wso2 http://twitter.com/#!/cobiacomm

Follow us:

http://twitter.com/#!/wso2

lean . enterprise . middleware

top related