36
Enterprise Level Applications on Windows Azure Mikkel Høy Sørensen Technical Manager at Sitecore Corporation [email protected]

Enterprise Level Applications on Windows Azure · Database Sharding •Scale out to two databases 1x20 GB 100% 2x10 GB 197% 87% 100% Throughput Response Time. SQL Fault tolerance

  • Upload
    others

  • View
    4

  • Download
    0

Embed Size (px)

Citation preview

Page 1: Enterprise Level Applications on Windows Azure · Database Sharding •Scale out to two databases 1x20 GB 100% 2x10 GB 197% 87% 100% Throughput Response Time. SQL Fault tolerance

Enterprise Level Applications on

Windows Azure

Mikkel Høy Sørensen

Technical Manager at Sitecore Corporation

[email protected]

Page 2: Enterprise Level Applications on Windows Azure · Database Sharding •Scale out to two databases 1x20 GB 100% 2x10 GB 197% 87% 100% Throughput Response Time. SQL Fault tolerance

Background

Page 3: Enterprise Level Applications on Windows Azure · Database Sharding •Scale out to two databases 1x20 GB 100% 2x10 GB 197% 87% 100% Throughput Response Time. SQL Fault tolerance

Background

• Technical Manager focusing on 3rd party products and technologies

• Responsible for products to ease integration with these

• Among these are Sitecore Azure

• Sitecore Azure enables seamless integration to Windows Azure

Page 4: Enterprise Level Applications on Windows Azure · Database Sharding •Scale out to two databases 1x20 GB 100% 2x10 GB 197% 87% 100% Throughput Response Time. SQL Fault tolerance

Building on Windows Azure

Page 5: Enterprise Level Applications on Windows Azure · Database Sharding •Scale out to two databases 1x20 GB 100% 2x10 GB 197% 87% 100% Throughput Response Time. SQL Fault tolerance

Building on Windows Azure

• Any architectural considerations i have to be aware of?

• What are the challenges of building application for Windows Azure?

• Will Windows Azure scale endlessly?

• How difficult is it to convert my existing Application?

Page 6: Enterprise Level Applications on Windows Azure · Database Sharding •Scale out to two databases 1x20 GB 100% 2x10 GB 197% 87% 100% Throughput Response Time. SQL Fault tolerance

Brief overview of Sitecore CMS

Page 7: Enterprise Level Applications on Windows Azure · Database Sharding •Scale out to two databases 1x20 GB 100% 2x10 GB 197% 87% 100% Throughput Response Time. SQL Fault tolerance

Brief overview of Sitecore CMS

• a Enterprise Content Management System

• designed for endless scaling

• supports multi server and multi location setups

• uses information push forward to high security requirements

Page 8: Enterprise Level Applications on Windows Azure · Database Sharding •Scale out to two databases 1x20 GB 100% 2x10 GB 197% 87% 100% Throughput Response Time. SQL Fault tolerance

Overall Architectural Considerations

Page 9: Enterprise Level Applications on Windows Azure · Database Sharding •Scale out to two databases 1x20 GB 100% 2x10 GB 197% 87% 100% Throughput Response Time. SQL Fault tolerance

Overall Architectural Considerations

• Runs on shared commodity hardware

• Everything has to be able to scale

• Multiple Geographical Locations

• Address scalability restrictions on single point of access data resources like databases

Page 10: Enterprise Level Applications on Windows Azure · Database Sharding •Scale out to two databases 1x20 GB 100% 2x10 GB 197% 87% 100% Throughput Response Time. SQL Fault tolerance

Typical setup

Page 11: Enterprise Level Applications on Windows Azure · Database Sharding •Scale out to two databases 1x20 GB 100% 2x10 GB 197% 87% 100% Throughput Response Time. SQL Fault tolerance

Typical setup

Publish new

content

Page 12: Enterprise Level Applications on Windows Azure · Database Sharding •Scale out to two databases 1x20 GB 100% 2x10 GB 197% 87% 100% Throughput Response Time. SQL Fault tolerance

Sitecore deployment on Azure

Page 13: Enterprise Level Applications on Windows Azure · Database Sharding •Scale out to two databases 1x20 GB 100% 2x10 GB 197% 87% 100% Throughput Response Time. SQL Fault tolerance

Sitecore deployment on Azure

Swap to

Azure

Sitecore converts

solution into Azure

format

Sitecore transfers

files to Azure geo

center(s)

Sitecore starts

instance(s)

Publish new

content

Page 14: Enterprise Level Applications on Windows Azure · Database Sharding •Scale out to two databases 1x20 GB 100% 2x10 GB 197% 87% 100% Throughput Response Time. SQL Fault tolerance

What does the automated deployment do

• Creates cloud databases with published data

• Setup Azure databases as publication targets

• Converts existing Website in to Web Role

• Configures Web Role to run on Cloud databases

Page 15: Enterprise Level Applications on Windows Azure · Database Sharding •Scale out to two databases 1x20 GB 100% 2x10 GB 197% 87% 100% Throughput Response Time. SQL Fault tolerance

Sitecore Azure Application

Page 16: Enterprise Level Applications on Windows Azure · Database Sharding •Scale out to two databases 1x20 GB 100% 2x10 GB 197% 87% 100% Throughput Response Time. SQL Fault tolerance

Sitecore Azure Application

Page 17: Enterprise Level Applications on Windows Azure · Database Sharding •Scale out to two databases 1x20 GB 100% 2x10 GB 197% 87% 100% Throughput Response Time. SQL Fault tolerance

Sitecore Azure Application

Page 18: Enterprise Level Applications on Windows Azure · Database Sharding •Scale out to two databases 1x20 GB 100% 2x10 GB 197% 87% 100% Throughput Response Time. SQL Fault tolerance

Sitecore Azure Application

Page 19: Enterprise Level Applications on Windows Azure · Database Sharding •Scale out to two databases 1x20 GB 100% 2x10 GB 197% 87% 100% Throughput Response Time. SQL Fault tolerance

Windows Azure Service Management REST API

• Control hosted services

• Create, update, swap and delete deployments

• Operate and get status on deployments

• Change sizing of environments

• Maintain certificates

• Get information about storage accounts

Page 20: Enterprise Level Applications on Windows Azure · Database Sharding •Scale out to two databases 1x20 GB 100% 2x10 GB 197% 87% 100% Throughput Response Time. SQL Fault tolerance

Web Roles

Page 21: Enterprise Level Applications on Windows Azure · Database Sharding •Scale out to two databases 1x20 GB 100% 2x10 GB 197% 87% 100% Throughput Response Time. SQL Fault tolerance

Web Roles

• Everything be able ton run multiple instances at once

• Web Roles can at any time be spun up / down, so must be stateless or able to recreate stats

• No disk access

• No support for legacy code

Page 22: Enterprise Level Applications on Windows Azure · Database Sharding •Scale out to two databases 1x20 GB 100% 2x10 GB 197% 87% 100% Throughput Response Time. SQL Fault tolerance

Converting Sitecore to Web Roles

• Sitecore consists of ~31 MB of compiled code

• Supports multiple web instances

• Can recreate state

• Not a single line was changed in order to support the Windows Azure platform

• Only changes done to Web Roles where configuration

Page 23: Enterprise Level Applications on Windows Azure · Database Sharding •Scale out to two databases 1x20 GB 100% 2x10 GB 197% 87% 100% Throughput Response Time. SQL Fault tolerance

Databases

Page 24: Enterprise Level Applications on Windows Azure · Database Sharding •Scale out to two databases 1x20 GB 100% 2x10 GB 197% 87% 100% Throughput Response Time. SQL Fault tolerance

Databases

• Must have clustered index

• Only one database server location pr. subscription

• No database replication (sync is available)

• Database size limitation

Page 25: Enterprise Level Applications on Windows Azure · Database Sharding •Scale out to two databases 1x20 GB 100% 2x10 GB 197% 87% 100% Throughput Response Time. SQL Fault tolerance

Latency

Page 26: Enterprise Level Applications on Windows Azure · Database Sharding •Scale out to two databases 1x20 GB 100% 2x10 GB 197% 87% 100% Throughput Response Time. SQL Fault tolerance

Latency

• Database responses from Web Roles where as

expected

• Updating or Creating database from on-premise

Production servers was slow due to latency

• Utilization of the bandwidth was very poor

Page 27: Enterprise Level Applications on Windows Azure · Database Sharding •Scale out to two databases 1x20 GB 100% 2x10 GB 197% 87% 100% Throughput Response Time. SQL Fault tolerance

Latency

source:

Page 28: Enterprise Level Applications on Windows Azure · Database Sharding •Scale out to two databases 1x20 GB 100% 2x10 GB 197% 87% 100% Throughput Response Time. SQL Fault tolerance

Latency

• Small 70mb database deployment from Los

Angeles to Singapore (avg. 185ms)

Serial Sql Statements

8123 Sql Statements

~52 Minutes

Parallel Sql Statements ~8 Minutes *

* The statement was now limit to bandwidth and server throughput

Page 29: Enterprise Level Applications on Windows Azure · Database Sharding •Scale out to two databases 1x20 GB 100% 2x10 GB 197% 87% 100% Throughput Response Time. SQL Fault tolerance

Database Sharding

Page 30: Enterprise Level Applications on Windows Azure · Database Sharding •Scale out to two databases 1x20 GB 100% 2x10 GB 197% 87% 100% Throughput Response Time. SQL Fault tolerance

Database Sharding

• Span you data a cross multiple databases

• Addresses database space limitations

• Ability to scale throughput

• Cost of 1x20GB is the same as 2x10GB

• Endless database size

Page 31: Enterprise Level Applications on Windows Azure · Database Sharding •Scale out to two databases 1x20 GB 100% 2x10 GB 197% 87% 100% Throughput Response Time. SQL Fault tolerance

Database Sharding

Principle behind database sharding

Data 1Data 2

Data 3Data 4

Data 1Data 2Data 3Data 4

Sharding Logic

Application

Page 32: Enterprise Level Applications on Windows Azure · Database Sharding •Scale out to two databases 1x20 GB 100% 2x10 GB 197% 87% 100% Throughput Response Time. SQL Fault tolerance

Database Sharding

• Scale out to two databases

1x20 GB100%

2x10 GB

197%

87%

100%

Response TimeThroughput

Page 33: Enterprise Level Applications on Windows Azure · Database Sharding •Scale out to two databases 1x20 GB 100% 2x10 GB 197% 87% 100% Throughput Response Time. SQL Fault tolerance

SQL Fault tolerance

Page 34: Enterprise Level Applications on Windows Azure · Database Sharding •Scale out to two databases 1x20 GB 100% 2x10 GB 197% 87% 100% Throughput Response Time. SQL Fault tolerance

Fault tolerance

• With software redundancy you can expect the server to close you connection.

• Faults will probably be more frequent when running on WAN then LAN.

• You should add retry capabilities to you application, to remove or reduce this.

• Best Practices for Building Reliable SQL Azure Database Client Applications: http://sqlcat.com/technicalnotes/archive/2010/06/17/best-practices-for-building-reliable-sql-azure-database-client-applications.aspx

Page 35: Enterprise Level Applications on Windows Azure · Database Sharding •Scale out to two databases 1x20 GB 100% 2x10 GB 197% 87% 100% Throughput Response Time. SQL Fault tolerance

Questions?

Page 36: Enterprise Level Applications on Windows Azure · Database Sharding •Scale out to two databases 1x20 GB 100% 2x10 GB 197% 87% 100% Throughput Response Time. SQL Fault tolerance