gwab2014 italy microsoft azure web sites

91
Windows Azure Web Sites Marco Parenzan 1nn0va Microsoft

Upload: marco-parenzan

Post on 15-Jan-2015

112 views

Category:

Technology


0 download

DESCRIPTION

Web Sites is the more rapid offert in Azure to adopt Cloud Computing....

TRANSCRIPT

Page 1: GWAB2014 Italy Microsoft Azure Web Sites

Windows Azure Web Sites

Marco Parenzan1nn0va

Microsoft

Page 2: GWAB2014 Italy Microsoft Azure Web Sites

Welcome To #GWAB 2014

• Welcome• The Charity• The Sponsors• The Social Fun• Agenda

Pordenone, 29 marzo 2014

Page 3: GWAB2014 Italy Microsoft Azure Web Sites

The Sponsors: These guys are doing it globally

 

 

 

 

 

 

 

A BIG THANK YOU

Page 4: GWAB2014 Italy Microsoft Azure Web Sites

The Sponsors: These guys are doing it locally

A BIG THANK YOU

Page 5: GWAB2014 Italy Microsoft Azure Web Sites

The Social Fun

Please share our “little” event on the WWW by any means

Use the HASHTAG

#GWAB#ITALY

extensively

Page 6: GWAB2014 Italy Microsoft Azure Web Sites

The Social Fun (part deux)Find all the online locations here

http://bit.ly/gwabflickrhttp://bit.ly/gwabTwitter (capital

‘T’)http://bit.ly/gwabfacebook

Page 7: GWAB2014 Italy Microsoft Azure Web Sites

Marco ParenzanFormazione & Divulgazione con 1nn0vaRicerca e Innovazione con Servizi Cgn@marco_parenzanit.linkedin.com/in/marcoparenzanwww.facebook.com/parenzan.marcowww.marcoparenzan.itwww.slideshare.net/marco.parenzangithub.com/marcoparenzanwww.scoop.it/u/marco-parenzan

marco [dot] parenzan [at] libero/live [dot] itwww.innovazionefvg.net

Developer e Architect in .NET e WebCloud Developer

Page 8: GWAB2014 Italy Microsoft Azure Web Sites

Moving away from premise

Page 9: GWAB2014 Italy Microsoft Azure Web Sites

What is “on premise”Packaged Software

Storage

Servers

Networking

O/S

Middleware

Virtualization

Data

Applications

Runtime

You m

anage

Page 10: GWAB2014 Italy Microsoft Azure Web Sites

Types of “cloud” offeringsPackaged Software

Storage

Servers

Networking

O/S

Middleware

Virtualization

Data

Applications

Runtime

You m

anage

Platform-as-a-Service

build

PaaSInfrastructure-as-a-

Service

host

IaaS

Page 11: GWAB2014 Italy Microsoft Azure Web Sites

Cloud ComputingPackaged Software

Storage

Servers

Networking

O/S

Middleware

Virtualization

Data

Applications

Runtime

You m

anage

Infrastructure(as a Service)

Storage

Servers

Networking

O/S

Middleware

Virtualization

Data

Applications

Runtime

Managed b

y v

endor

You m

anage

Platform(as a Service)

Managed b

y v

endor

You m

anage

Storage

Servers

Networking

O/S

Middleware

Virtualization

Applications

Runtime

Data

Software(as a Service)

Managed b

y v

endor

Storage

Servers

O/S

Middleware

Virtualization

Applications

Runtime

Data

Networking

Page 12: GWAB2014 Italy Microsoft Azure Web Sites

Magic Quadrant for Enterprise Application Platform as a Service http://

www.gartner.com/technology/reprints.do?id=1-1P502BX&ct=140108&st=sb Microsoft's offering, Windows Azure, has evolved into an environment that supports IaaS and PaaS models. As a result of adding full IaaS capabilities, as well as fleshing out its private cloud strategy, the vendor now provides the onramps that are making PaaS much more approachable for enterprises.

Page 13: GWAB2014 Italy Microsoft Azure Web Sites

PaaS for the Modern Web

Paas is secureEnterprise Grade Availability with support for SSL and AD

PaaS is flexibleWeb hosting your way with choice of language, framework, database, and platform

PaaS is scalableScale out or up in seconds on a Load Balanced, Always up to date, Global Infrastructure

Page 14: GWAB2014 Italy Microsoft Azure Web Sites

The Benefits of PaaS

Paas is cheaperReason: There’s less admin and management work to doBenefit: Organizations spend less supporting applications

PaaS is fasterReason: There’s less work for developers to doBenefit: Applications can go from idea to availability more quickly

PaaS is lower riskReason: The platform does more, leaving fewer opportunities for errorBenefit: Creating and running applications gets more reliable

PaaS is always up to dateReason: Runs on Windows server 2012.Benefit: Always patched. Always running latest versions of frameworks

Page 15: GWAB2014 Italy Microsoft Azure Web Sites

Running Apps on the Cloud

Page 16: GWAB2014 Italy Microsoft Azure Web Sites

cloud services

The first model (2010+)

Page 17: GWAB2014 Italy Microsoft Azure Web Sites

virtual machines cloud services

The common models (2012+)

Page 18: GWAB2014 Italy Microsoft Azure Web Sites

virtual machines

Windows Server and Linux Flexible Workload Support Virtual Private Networking

Page 19: GWAB2014 Italy Microsoft Azure Web Sites

cloud services

Build infinitely scalable apps and services

Support rich multi-tier architectures

Automated application management

Page 20: GWAB2014 Italy Microsoft Azure Web Sites

From first days of Azure, PaaS is…… set of cloud services, a container of related service

roles

Web Role Worker Role

Page 21: GWAB2014 Italy Microsoft Azure Web Sites

Fault Domains

99.95% Uptime GuaranteeRequires 2 or more instance per role

Role instance are isolated by fault domainFault domains isolate VMsFault domains provide redundancyAt least two fault domains per role

Page 22: GWAB2014 Italy Microsoft Azure Web Sites

Roles and InstancesExample role with nine virtual machines distributed across three fault domains

ROLE

VM1 VM3

VM5 VM8

VM2 VM4

VM6 VM9

VM6 VM9

Page 23: GWAB2014 Italy Microsoft Azure Web Sites

Service Definition• <?xml version="1.0" encoding="utf-8"?>• <ServiceDefinition name="WebDeploy" xmlns="http://schemas.microsoft.com/ServiceHosting/2008/10/ServiceDefinition

">•<WebRole name="WebUX">

•<Startup>•<Task commandLine="..\Startup\EnableWebAdmin.cmd" executionContext="elevated" taskType="simple" />

•</Startup>•<Imports>

•<Import moduleName="RemoteAccess" />•<Import moduleName="RemoteForwarder"/>

•</Imports>•<Sites>

•<Site name="Web">•<Bindings>• <Binding name="HttpIn" endpointName="HttpIn"/>•</Bindings>

•</Site>•</Sites>•<Endpoints>

•<InputEndpoint name="HttpIn" protocol="http" port="80"/>•<InputEndpoint name="mgmtsvc" protocol="tcp" port="8172" localPort="8712"/>

•</Endpoints>

Page 24: GWAB2014 Italy Microsoft Azure Web Sites

Some common problems

+20 min deploy time.No error checking.Failures meant you had to start over.

Page 25: GWAB2014 Italy Microsoft Azure Web Sites

Some common requests

Boss wants a demo environment?Testers want the latest features?Deployed dev ConnStr to production?

Page 26: GWAB2014 Italy Microsoft Azure Web Sites

YOUR APP=JUST APP+DATA

Page 27: GWAB2014 Italy Microsoft Azure Web Sites

Models for Building and Running Apps

Page 28: GWAB2014 Italy Microsoft Azure Web Sites

web sites virtual machines mobile servicescloud services

The modern offering (2013+)

Page 29: GWAB2014 Italy Microsoft Azure Web Sites

mobile services

Build Node.js or ASP.NET, Just data from a table Push to mobile devices

Page 30: GWAB2014 Italy Microsoft Azure Web Sites

web sites

Build with ASP.NET, Node.js or PHP

Deploy in seconds with FTP, Git or TFS

Start for free, scale up as your traffic grows

Page 31: GWAB2014 Italy Microsoft Azure Web Sites

On-Premises

Models for Building and Running Apps

Virtualization

O/S

Hardware

Native Code

Custom Software

Network

Data

Applications

Firewall

Web Sites

Applications

Data

Cloud Services

Native Code

Startup Tasks

Applications

Firewall Rules

Data

Virtual Network

Virtual Machines

Native Code

Custom Software

Virtual Network

Data

Applications

Firewall Rules

O/S

Mobile Services

Applications

Data

Auth

Notifications

Page 32: GWAB2014 Italy Microsoft Azure Web Sites

Today

Near instant deploy time!Many errors cause warnings!Failures can happen but who cares?

Page 33: GWAB2014 Italy Microsoft Azure Web Sites

Web Sites Features

Page 34: GWAB2014 Italy Microsoft Azure Web Sites

Some misconceptionsWeb Sites is a frequently underestimated platform

Blogs & CMS’s

Only for startups

No logging or monitoring

Lacks on-premises integration

No middle tier

Page 35: GWAB2014 Italy Microsoft Azure Web Sites

Start Simple

Get started with 10 free web sites

Create new sites in seconds

Easily manage and scale your sites

Automatic load balancing and shared storage across instances

Scale out or up to reserved instances for improved performance and scale

Page 36: GWAB2014 Italy Microsoft Azure Web Sites

Code Smart

Use ASP.NET, ASP, PHP, or Node.js

SQL Azure or MySQL databases

Start with open source apps and frameworks

Develop with VS and WebMatrix (and Monaco!)

Supports any Web development tool on any platform (Windows, OSX, Linux)

Page 37: GWAB2014 Italy Microsoft Azure Web Sites

Cdn

Access to other Azure Services

Caching

Media

Big data

Analytics

Mobile

Integration

Service bus Web sites

SQL database noSQL DB

Blob storage

Cloud services

Virtual Machines

Identity

Messaging

Networking

Traffic

Storage

Page 38: GWAB2014 Italy Microsoft Azure Web Sites

Go Live

Rapid deployment for quick iteration

Integrated source control with Team Foundation Server (TFS) and Git

Built-in monitoring of perf and usage data

Quick access to request logs, failed requests diagnostics and diagnostics

Page 39: GWAB2014 Italy Microsoft Azure Web Sites

Enterprise grade

High availability with SLA on reserve instances.A global network of data centers.Guaranteed SLA and 24/7 support.

Enterprise grade.

Load balanced Up to date Easily scale Economical

Page 40: GWAB2014 Italy Microsoft Azure Web Sites

Architecture

Page 41: GWAB2014 Italy Microsoft Azure Web Sites

How does Windows Azure websites work?Cloud first by design, but also available on premise.

SQL based configuration.

Dynamic provisioning of sites on demand.

Network-based storage (Azure xDrive, SMB, NAS, SAN).

Intelligent load balancing.

Page 42: GWAB2014 Italy Microsoft Azure Web Sites

Load balanced by default

Traffic automatically load balanced across two or more servers.

Page 43: GWAB2014 Italy Microsoft Azure Web Sites

Websites architectureAll DBs are running on SQL Azure.

Azure blobs as durable storage.

Windows Azure worker roles.

Monitor resources usage.

Dynamic web activation service.

W3WP.exe IIS application pool process.

Azure LB

IIS ARR (LB)

Deployment server(s)

API frontend

Web server

Storage controller

Site (W3WP.exe)

Metering

DWAS

Runtime DB

Websites DB’s

Cloud drive

Page 44: GWAB2014 Italy Microsoft Azure Web Sites

Web Sites are not in IIS. They only are when a request comes

in!

Page 45: GWAB2014 Italy Microsoft Azure Web Sites

Load balancer

Layers 1st layer: Windows Azure load balancer 2nd layer: IIS + ARR

ARR “Reverse proxy” Verifies hosting database (plans, quotas, …) Negotiates best node to run your site on Site not used much? Put it on a highly loaded machine

Page 46: GWAB2014 Italy Microsoft Azure Web Sites

Project Kudu

“The engine behind git deployments on Windows Azure”

Open source (www.github.com/projectkudu/kudu)

Provides git deployments Provides builds Provides sandboxing Provides hosting

Page 47: GWAB2014 Italy Microsoft Azure Web Sites

Development

Page 48: GWAB2014 Italy Microsoft Azure Web Sites

Open and flexible

Choice of languages.

Choice of databases.

Web app gallery. Zero lock in.

Page 49: GWAB2014 Italy Microsoft Azure Web Sites

Best Visual Studio Experience

Move existing ASP.NET websites.

Deploy and manage in Visual Studio.

Team foundation services integration.

Page 50: GWAB2014 Italy Microsoft Azure Web Sites

Choice of language

Node.js: 0.6.17, 0.6.20, 0.8.2

PHP: 5.3PHP: 5.4

ASP.NETNET: 3.5, 4.5, 4.5.1 Python: 2.7

Bring a stack: FastCGI basedRubyJava

Choice of frameworks and languages.

Page 52: GWAB2014 Italy Microsoft Azure Web Sites

Zero lock in

IIS

Web sites for Windows server

Windows Azure web sites

Hosted and private cloud

Public cloud

Web server

Page 53: GWAB2014 Italy Microsoft Azure Web Sites

Deployment

Page 54: GWAB2014 Italy Microsoft Azure Web Sites

Git TFSWeb

Deploy

FTP

CodePlex, BitBucket &

GitHub

Supported Publishing Methods

Page 55: GWAB2014 Italy Microsoft Azure Web Sites

Deploy and manage in Visual Studio Import your Azure subscription into Visual Studio for deployment and management.

Right click from Visual Studio to deploy, manage and configure.

Page 56: GWAB2014 Italy Microsoft Azure Web Sites

Team foundation services integrationTeam development.Continuous delivery.

Page 57: GWAB2014 Italy Microsoft Azure Web Sites

Scaling

Page 58: GWAB2014 Italy Microsoft Azure Web Sites

Windows Azure is a scalable platformWhich allows you to add and remove resourcesWith flexible pricing

Scaling is manual, based on your decisions

Understand elasticity

Flexible

Page 59: GWAB2014 Italy Microsoft Azure Web Sites

Understand elasticity You can automate scaling:

Service Management API PowerShell Writing your own code

3rd party tools Or use Autoscaling Application Block

Page 60: GWAB2014 Italy Microsoft Azure Web Sites

Scalability Scaling up and scaling out

0 1 2 3 4 5 6 7 8

Instances

Throughput

Instance Capacity

Quota

Page 61: GWAB2014 Italy Microsoft Azure Web Sites

What does scaling mean for my apps?It depends… but some general practices apply.• Capacity plan• Proper decomposition of system• Stateless design• Scale at all layers• Throttling

Page 62: GWAB2014 Italy Microsoft Azure Web Sites

Different Levels of ScalabilityStateless Shared States Global States

R

R

R

R

R

R

R

R

R

R

S

S

R

R

R

R

R

S

R

R

R

R

R

R

R

R

R

R

R

R

R

SR

RS

R

R

R

R

R

S

R

R

R

R

R

S

Router

Eliminate global statesSeparate states and actions

Page 63: GWAB2014 Italy Microsoft Azure Web Sites

Separate actions and states Externalize states

Cache session state provider (Microsoft.Web.DistributedCache.DistributedCacheSessionStateStoreProvider, Microsoft.Web.DistributedCache)

Separate actions and states Job creator Job queue Job Handler

Job Creator

Job Handler

Job Queue

Job Handler

Page 64: GWAB2014 Italy Microsoft Azure Web Sites

scale

Free

Shared

Standard

Multi-tenant. Daily quotas

Multi-tenant. Daily quotas

Dedicated VMs. No quotas

Page 65: GWAB2014 Italy Microsoft Azure Web Sites

Easily scaleScale up.Scale out.Automatic scaling.

:-)

:-):-) :-)

:-)

:-) :-)

Page 66: GWAB2014 Italy Microsoft Azure Web Sites

Using storage

Page 67: GWAB2014 Italy Microsoft Azure Web Sites

Storage: What are our options? Benefits:

Non-relational structured storageMassive scale-out

Tables Storage

Benefits: Big filesBlobs

Benefits: Persistent Async MessagingEnqueue, Dequeue

Queues

Benefits: Relational databaseHighly availableManaged for you as a service

SQL Databas

e

Page 68: GWAB2014 Italy Microsoft Azure Web Sites

Windows Azure Storage

Storage in the CloudScalable, durable, and availableAnywhere at anytime accessOnly pay for what the service uses

Exposed via RESTful Web ServicesUse from Windows Azure ComputeUse from anywhere on the internet

Page 69: GWAB2014 Italy Microsoft Azure Web Sites

Windows Azure Storage AccountCan CDN Enable AccountBlobs delivered via 24 global CDN nodes

Can co-locate storage account with compute accountExplicitly or using affinity groups

Accounts have two independent 512 bit shared secret keys

100 TBs per account

Geo-ReplicationStorage AnalyticsLogs: Provide trace of executed requests for your storage accountsMetrics: Provide summary of key capacity and request statistics for Blobs, Tables, and Queues

Improved HTTP headers for Blobs

Page 70: GWAB2014 Italy Microsoft Azure Web Sites

The Storage Client API

In this presentation we’ll cover the underlying

RESTful APICan call these from any HTTP cliente.g. Flash, Silverlight, etc…

Client API from SDK Microsoft.WindowsAzure.StorageClientProvides a strongly typed wrapper around REST services

Page 71: GWAB2014 Italy Microsoft Azure Web Sites

Scenarios

Page 72: GWAB2014 Italy Microsoft Azure Web Sites

Windows Azure

Scenario: Enterprise PizzaPizza-ordering site that currently saves order data

Web Site SQL

Web Site Collects Data

Data sent to SQL database

Page 73: GWAB2014 Italy Microsoft Azure Web Sites

Developing a Middle TierProcessing Web Site data using Cloud Services

Web Site StoredQueue

Web Site Collects Data

Data Sent to QueueData Pulled from Queue and ProcessedData Stored

Worker

Windows Azure

Page 74: GWAB2014 Italy Microsoft Azure Web Sites

Developing an On-Premise Middle TierProcessing Web Site data using an internal app

Web Site StoredQueue Worker

Windows AzureCorporate Network

Page 75: GWAB2014 Italy Microsoft Azure Web Sites

Service Bus TopicsCollecting data from a Web Site using Subscriptions

Corporate NetworkWindows Azure

Web Site

Service Bus

Web Site Collects Data

Application

Results Published to Service BusInternal Application Subscribed to Service Bus Gets Messages

On-premise Application Displays Message

On-premise App

Page 76: GWAB2014 Italy Microsoft Azure Web Sites

Corporate NetworkWindows Azure

Service Bus RelaysSending messages between tiers with Service Bus

Web Site On-premise App

Service Bus

On start, Web Site hosts a WCF service using a Service Bus Relay bindingOn start, on-premise app hosts a WCF service using a Service Bus Relay binding

Web Site sends a message to the WCF service hosted by the on-premise appService Bus relays the message to the on-premise appOn-premise application executes functionalityOn-premise app sends a message to the WCF service hosted by the Web SiteService Bus relays the message to the Web Site

Page 77: GWAB2014 Italy Microsoft Azure Web Sites

Data MartsUsing data from an enterprise in a Web Site using Service Bus

Corporate NetworkWindows Azure

Database

Service Bus

Internal Application Sends Data to Service Bus

Application

Data persisted to SQL databaseWeb site has access to data

SQL Web Site

WCF Service in Web Site is hit using Service Bus Relays

Page 78: GWAB2014 Italy Microsoft Azure Web Sites

Windows Azure Store

Page 79: GWAB2014 Italy Microsoft Azure Web Sites

Windows Azure StoreConsume services from ecosystem of partnersEasily try and purchaseBilling integrated within your Azure bill

Page 80: GWAB2014 Italy Microsoft Azure Web Sites

Windows Azure Web App Gallery

Ready-to-Go Open Source Web Applications, Frameworks, and Templates

Page 81: GWAB2014 Italy Microsoft Azure Web Sites

Windows Azure Store

Discover, Purchase & Provision PremiumServices

Page 82: GWAB2014 Italy Microsoft Azure Web Sites

Web app gallery

Page 83: GWAB2014 Italy Microsoft Azure Web Sites

Pricing and Offers

Page 84: GWAB2014 Italy Microsoft Azure Web Sites

Estimating On-Premises Server CostsQuestion: How much does it cost to procure and operate monthly?A. $100 / monthB. $500 / monthC. $750 / monthD. $1,000 / monthAnswer: Average ~ $630 / month

Page 85: GWAB2014 Italy Microsoft Azure Web Sites

Estimating Cloud Costs

http://www.windowsazure.com/en-us/pricing/calculator/

Page 86: GWAB2014 Italy Microsoft Azure Web Sites

Pay only for what you use

Page 87: GWAB2014 Italy Microsoft Azure Web Sites

Shared vs. reserved instancesShared instances Reserved instances

Price FREE for 12 months Azure S,M,L instances

Number of sites Up to 10 Up to 100

Maximum scale 10 instances 10 instances (call support for more)

Storage 1GB (shared by all sites) 10GB (shared by all sites) 

Storage transactionsUnlimited (abstracted by storage subsystem) Unlimited (abstracted by storage subsystem)

SQL database Standard SQL database Standard SQL database

MySQL Includes one 20MB database Includes one 20MB database

BandwidthIngress—UnlimitedEgress—165MB/day (5GB/month) 

Ingressn—limitedEgress—Azure bandwidth rates (above 5GB/month)

Custom domains Not available Supported

SSL None Supported

SLA None Yes

Support FAQ, forum Email, phone, FAQ, and forum

Page 88: GWAB2014 Italy Microsoft Azure Web Sites

Pricing Pay as You Go Monthly Commitment

Page 89: GWAB2014 Italy Microsoft Azure Web Sites

Conclusions

Page 90: GWAB2014 Italy Microsoft Azure Web Sites

Conclusions

Windows Azure Web Sites are an appealing opportunity to enter into the cloudWeb Sites can growth to more “classic” cloud services as needed

Page 91: GWAB2014 Italy Microsoft Azure Web Sites

ThanksQ & A