Design Patterns in the Windows Azure Platform

While most Cloud Platforms are viewed as Virtualization, Hypervisors, Elastic Instances and infrastructure-related flexibility that enables you to arrive at the dynamic infrastructure, Windows Azure is a complete development platform where the scalability of the multi-tiered systems can be enabled through the usage of ‘Design Patterns'.

Below are the common ‘Design Patterns' that can be realized using the Windows Azure as a PaaS platform.

Web Role & Worker RoleWindows Azure currently supports the following two types of roles:

Web role: A web role is a role that is customized for web application programming as supported by IIS 7 and ASP.NET.

Worker role: A worker role is a role that is useful for generalized development, and may perform background processing for a web role.

A service must include at least one role of either type, but may consist of any number of web roles or worker roles.

Role Network Communication|A web role may define a single HTTP endpoint and a single HTTPS endpoint for external clients. A worker role may define up to five external endpoints using HTTP, HTTPS, or TCP. Each external endpoint defined for a role must listen on a unique port.

Web roles may communicate with other roles in a service via a single internal HTTP endpoint. Worker roles may define internal endpoints for HTTP or TCP.

Both web and worker roles can make outbound connections to Internet resources via HTTP or HTTPS and via Microsoft .NET APIs for TCP/IP sockets.

So we can have a ASP.NET front end application hosted on a VM which is a web role and a WCF Service hosted VM which is a worker role and the following design patterns can be applied.

Session FacadeWorker Role VM as a facade is used to encapsulate the complexity of interactions between the business objects participating in a workflow. The Session Facade manages the business objects, and provides a uniform coarse-grained service access layer to clients.

The below diagram shows the implementation of Session Façade pattern in Windows Azure.

Business Delegate / Service LocatorThe Business Delegate reduces coupling between presentation-tier clients and business services. The Business Delegate hides the underlying implementation details of the business service, such as lookup and access details of the Azure / Worker role architecture.

Service Locator object abstracts server lookup, and instance creation. Multiple clients can reuse the Service Locator object to reduce code complexity, provide a single point of control, and improve performance by providing a caching facility.

These two patterns together provide valuable support for Dynamic Elasticity and Load Balancing in a cloud environment. We can have logic in these roles (Business Delegate, Service Locator) such that the Virtual Machines with the least load are selected for Service and providing higher scalability.

Typical Activities that can be loaded to a Business Delegate Worker Role are:

Monitoring Load Metrics using APIs for all the other Worker Role VMs

Gather and Persist Metrics

Rule Based Scaling

Adding and Removing Instances

Maintain and Evaluate Business Rules for Load Balancing

Auto Scaling

Health Monitoring

Abstract VM migration details from Web Roles

Other PatternsWindows Azure's coarse grained, asynchronous architecture of Web Roles and Worker Roles facilitates several other common design patterns mentioned below, which makes this a robust enterprise development platform and not just a Infrastructure Virtualization Enabler.

Transfer Object Assembler

Value List Handler

Transfer Object

Data Access Object

Model View Controller Architecture

Front controller

Dispatcher View

SummaryDesign patterns help in modularizing software development and deployment process , so that the building blocks can be developed independently and yet tied together without much tight coupling between them. Utilizing them for the Windows Azure development will compliment the benefits already provided by the Cloud platform.

Microsoft's Azure Services Platform is a cloud platform (cloud computing platform as a service) offering that "provides a wide range of Internet services that can be consumed from both on-premises environments or the Internet" - Microsoft's first step into cloud computing based on its "Software Plus Services" philosophy.

Cloud Expo

Cloud Computing & All That
It Touches In One Location Cloud Computing - Big Data - Internet of Things
SDDC - WebRTC - DevOps
Cloud computing is become a norm within enterprise IT.

The competition among public cloud providers is red hot, private cloud continues to grab increasing shares of IT budgets, and hybrid cloud strategies are beginning to conquer the enterprise IT world.

Big Data is driving dramatic leaps in resource requirements and capabilities, and now the Internet of Things promises an exponential leap in the size of the Internet and Worldwide Web.

The world of SDX now encompasses Software-Defined Data Centers (SDDCs) as the technology world prepares for the Zettabyte Age.

Add the key topics of WebRTC and DevOps into the mix, and you have three days of pure cloud computing that you simply cannot miss.

Delegates will leave Cloud Expo with dramatically increased understanding the entire scope of the entire cloud computing spectrum from storage to security.

Cloud Expo - the world's most established event - offers a vast selection of 130+ technical and strategic Industry Keynotes, General Sessions, Breakout Sessions, and signature Power Panels. The exhibition floor features 100+ exhibitors offering specific solutions and comprehensive strategies. The floor also features two Demo Theaters that give delegates the opportunity to get even closer to the technology they want to see and the people who offer it.

Attend Cloud Expo. Craft your own custom experience. Learn the latest from the world's best technologists. Find the vendors you want and put them to the test.