1: Introduction to Windows Azure
This content and the technology described is outdated and is no longer being maintained. For more information, see Transient Fault Handling.
|On this page:|
|About Microsoft Azure | Azure Services and Features - Compute Environment, Data Management, Networking Services, Other Services | Developing Azure Applications | Managing, Monitoring, and Debugging Azure Applications | Managing SQL Azure Databases | Upgrading Azure Applications | Azure Subscription and Billing Model | Estimating Your Costs | More Information|
This chapter provides a brief description of the Microsoft Azure™ technology platform, the services it provides, and the opportunities it offers for on-demand, cloud-based computing where the cloud is a set of interconnected computing resources located in one or more data centers. The chapter also provides links to help you find more information about the features of Azure, the techniques and technologies used in this series of guides, and the sample code that accompanies them.
|Azure is a fast-moving platform, so for the very latest information about any of the features described in this chapter, you should follow the provided links.|
The primary purpose of this developer guide is to show how to use the Enterprise Library Integration Pack for Microsoft Azure with your Azure applications. The accompanying reference implementation (sample demo), and the associated hands-on labs utilize many of the features and services available in Azure, so it is useful to have an understanding of Azure itself before you begin using the Enterprise Library Integration Pack for Microsoft Azure. If you are already familiar with Azure, you can skip this chapter and move on to the chapters that describe the Enterprise Library Integration Pack for Microsoft Azure and the reference implementation, called the Tailspin Surveys application.
About Microsoft Azure
Organizations can use the cloud to deploy and run applications and to store data. On-premises applications can use cloud-based resources as well. For example, an application located on an on-premises server, a rich client that runs on a desktop computer, or one that runs on a mobile device can use storage that is located on the cloud.
For more information about hybrid solutions, see the integration guide at http://wag.codeplex.com/.
Azure abstracts hardware resources through virtualization. Each application that is deployed to Azure runs on one or more virtual machines (VMs). These deployed applications behave as though they were on a dedicated computer, although they might share physical resources such as disk space, network I/O, or CPU cores with other VMs on the same physical host. Two key benefits of an abstraction layer above the physical hardware are portability and scalability. Virtualizing a service allows it to be moved to any number of physical hosts in the data center. By combining virtualization technologies, commodity hardware, multi-tenancy, and aggregation of demand, Microsoft and our customers can achieve economies of scale. Such economies generate higher data center utilization (that is, more useful work-per-dollar hardware cost) and, subsequently, savings that are passed along to you.
|Azure can help you achieve portability and scalability for your applications, and reduce your running costs and total cost of ownership (TCO).|
Virtualization also allows you to have both vertical scalability and horizontal scalability. Vertical scalability means that, as demand increases, you can increase the number of resources, such as CPU cores or memory, on a specific VM. Horizontal scalability means that you can add more instances of VMs that are copies of existing services. All these instances are load balanced at the network level so that incoming requests are distributed among them.
At the time of this writing, Azure encompasses Microsoft Azure and SQL Azure.
Microsoft Azure provides a Microsoft® Windows Server®-based computing environment for applications and persistent storage for both structured and unstructured data, as well as asynchronous messaging. Azure also provides a range of services that helps you connect users and on-premises applications to cloud-hosted applications, manage authentication, use inter-service messaging, and implement data management and related features such as caching.
Azure also includes a range of management services that allows you to control all these resources, either through a web-based user interface (a web portal) or programmatically. In most cases there is a REST-based API that can be used to define how your services will work. Most management tasks that can be performed through the web portal can also be performed using the API.
SQL Azure is essentially SQL Server® provided as a service in the cloud.
Finally, there is a comprehensive set of tools and software development kits (SDKs) that allow you to develop, test, and deploy your applications. For example, you can develop and test your applications in a simulated local environment, provided by the Compute Emulator and the Storage Emulator. Most tools are also integrated into development environments such as Microsoft Visual Studio® development system. In addition, there are third-party management tools available.
Azure Services and Features
The range of services and features available on Azure and SQL Azure target specific requirements for your applications. When you subscribe to Azure, you can choose which of the features you require, and you pay only for the features you use. You can add and remove features from your subscription whenever you wish. The billing mechanism for each service depends on the type of features the service provides. For more information on the billing model, see "Azure Subscription and Billing Model," later in this chapter.
The services and features available change as Azure continues to evolve. The following four sections of this chapter briefly describe the main services and features available at the time of this writing, subdivided into the categories of Compute Environment, Data Management, Networking Services, and Other Services.
|Azure includes a range of services that can simplify development, increase reliability, and make it easier to manage your cloud-hosted applications.|
For more information about all of the Azure services and features, see "Azure Features" on the Azure Portal. For specific development and usage guidance on each feature or service, see the resources referenced in the following sections.
To use any of these features and services you must have a subscription to Azure. A valid Windows Live® ID is required when signing up for an Azure account. For more information, see "Azure Offers."
The Azure compute environment consists of a platform for applications and services hosted within one or more roles. The types of roles you can implement in Azure are:
- Azure Compute (Web and Worker Roles). An Azure application consists of one or more hosted roles running within the Azure data centers. Typically there will be at least one web role that is exposed for access by users of the application. A web role is supported by Internet Information Service (IIS) 7.0 and ASP.NET. The application may contain additional roles, including worker roles, that are typically used to perform background processing and support tasks for web roles. For more detailed information, see "Building an Application that Runs in a Hosted Service."
- Virtual Machine (VM role). This role allows you to host your own custom instance of the Windows Server 2008 R2 Enterprise or Windows Server 2008 R2 Standard operating system within an Azure data center. For more detailed information see "Creating Applications by Using a VM Role in Azure."
The Tailspin Surveys application uses both web and worker roles. For additional information and guidance about the use of web and worker roles see the associated guides "Moving Applications to the Cloud" and "Developing Applications for the Cloud" which are available at Cloud Development on MSDN. Each of these guides also includes a set of hands-on labs.
Azure, SQL Azure, and the associated services provide opportunities for storing and managing data in a range of ways. The following data management services and features are available:
- Azure Storage. This provides four core services for persistent and durable data storage in the cloud. The services support a REST interface that can be accessed from within Azure-hosted or on-premises (remote) applications. For information about the REST API, see "Azure Storage Services REST API Reference." The four storage services are listed below.
- The Azure Table Service provides a table-structured storage mechanism and supports queries for managing the data. The Azure Table Service is a NoSQL offering that provides schema-less storage. It is primarily aimed at scenarios where large volumes of data must be stored, while being easy to access and update. For more detailed information see "Table Service Concepts" and "Table Service REST API."
- The Binary Large Object (BLOB) Service provides a series of containers aimed at storing text or binary data. It provides both Block BLOB containers for streaming data, and Page BLOB containers for random read/write operations. For more detailed information see "Understanding Block Blobs and Page Blobs" and "Blob Service REST API."
- The Queue Service provides a mechanism for reliable, persistent messaging between role instances, such as between a web role and a worker role. For more detailed information see "Queue Service Concepts" and "Queue Service REST API."
- Azure Drives provide a mechanism for applications to mount a single volume NTFS VHD as a Page BLOB, and upload and download VHDs via the BLOB. For more detailed information see "Azure Drive."
- SQL Azure Database. This is a highly available and scalable cloud database service built on SQL Server technologies, that supports the familiar T-SQL-based relational database model. It can be used with applications hosted in Azure, and with other applications running on-premises or hosted elsewhere. For more detailed information see "SQL Azure Database."
- Data Synchronization. SQL Azure Data Sync is a cloud-based data synchronization service built on Microsoft Sync Framework technologies. It provides bi-directional data synchronization and data management capabilities, allowing data to be easily shared between multiple SQL Azure databases and between on-premises and SQL Azure databases. For more detailed information see "Microsoft Sync Framework Developer Center."
- Caching. This service provides a distributed, in-memory, low latency and high throughput application cache service that requires no installation or management, and dynamically increases and decreases the cache size as required. It can be used to cache application data, ASP.NET session state information, and for ASP.NET, page output caching. For more detailed information see "Caching Service (Azure)."
The Tailspin Surveys application uses both Azure storage and SQL Azure. For additional information and guidance about the use of Azure storage and SQL Azure see the associated guides "Moving Applications to the Cloud" and "Developing Applications for the Cloud" which are available at Cloud Development on MSDN. Each of these guides also includes a set of hands-on labs.
Azure provides several networking services that you can take advantage of to maximize performance, implement authentication, and improve manageability of your hosted applications. These services include the following:
- Content Delivery Network (CDN). The CDN allows you to cache publicly available static data for applications at strategic locations that are closer (in network delivery terms) to end users. The CDN uses a number of data centers at many locations around the world, which store the data in BLOB storage that has anonymous access. These do not need to be locations where the application is actually running. For more detailed information see "Delivering High-Bandwidth Content with the Azure CDN."
- Virtual Network Connect. This service allows you to configure roles of an application running in Azure and computers on your on-premises network so that they appear to be on the same network. It uses a software agent running on the on-premises computer to establish an IPsec-protected connection to the Azure roles in the cloud, and provides the capability to administer, manage, monitor, and debug the roles directly. For more detailed information see "Connecting Local Computers to Azure Roles."
- Virtual Network Traffic Manager. This is a service that allows you to set up request redirection and load balancing based on three different techniques. Typically you will use Traffic Manager to maximize performance by using the Performance technique to redirect requests to the instance of your application in the data center closest to the user. Alternative load balancing methods available are Failover and Round Robin. For more detailed information see "Azure Traffic Manager."
- Access Control (ACS). This is a standards-based service for identity and access control that makes use of a range of identity providers (IdPs) that can authenticate users. ACS acts as a Security Token Service (STS), or token issuer, and makes it easier to take advantage of federation authentication techniques where user identity is validated in a realm or domain other than that in which the application resides. An example is controlling user access based on an identity verified by an identity provider such as Windows Live® ID or Google. For more detailed information see "A Guide to Claims-Based Identity and Access Control(2nd Edition)."
- Service Bus. This provides a secure messaging and data flow capability for distributed and hybrid applications, such as communication between Azure hosted applications and on-premises applications and services, without requiring complex firewall and security infrastructures. It can use a range of communication and messaging protocols and patterns to provide delivery assurance and reliable messaging, can scale to accommodate varying loads, and can be integrated with on-premises BizTalk Server artifacts. For more detailed information see "Service Bus."
For additional information and guidance about the use of Azure storage and SQL Azure see the associated guides "Moving Applications to the Cloud" and "Developing Applications for the Cloud" which are available at Cloud Development on MSDN. Each of these guides also includes a set of hands-on labs.
Detailed guidance on using ACS can be found in the associated document, "A Guide toClaims-Based Identity and Access Control(2nd Edition)" and in the hands-on labs for that guide.
Azure provides the following additional services:
- Business Intelligence Reporting. This service allows you to develop and deploy to the cloud business operational reports generated from data stored in a SQL Azure database. It is built upon the same technologies as SQL Server Reporting Services, and lets you use familiar tools to generate reports. Reports can be easily accessed through the Azure Management Portal, through a web browser, or directly from within your Azure and on-premises applications. For more detailed information see "SQL Azure Reporting."
- Marketplace. This is an online facility where developers can share, find, buy, and sell building block components, training, service templates, premium data sets, and finished services and applications needed to build Azure applications. For more detailed information see "Azure Marketplace" on MSDN and "Azure Marketplace" (AppMarket).
Developing Azure Applications
Typically, on Microsoft® Windows®, you will use Visual Studio 2010 with the Azure Tools for Microsoft Visual Studio. The Azure Tools provide everything you need to create Azure applications, including local compute and storage emulators that run on the development computer. This means that you can write, test, and debug applications before deploying them to the cloud. The tools also include features to help you deploy applications to Azure and manage them after deployment.
|You can build and test Azure applications using the compute and storage emulators on your development computer.|
You can download the Azure Tools for Microsoft Visual Studio, and development tools for other platforms and languages such as iOS, Eclipse, Java, Ruby, and PHP from "Azure Tools."
For a useful selection of videos, QuickStart examples, and hands-on labs that cover a range of topics to help you get started building Azure applications, see "Learn Azure and SQL Azure" and "Design. Code. Scale."
The MSDN "Developing Applications for Azure" topic includes specific examples and guidance for creating hosted services, using the Azure Tools for Microsoft Visual Studio to package and deploy applications, and a useful QuickStart example.
The Azure Training Kit contains hands-on labs to get you started quickly.
For a list of useful resources for developing and deploying databases in SQL Azure, see "Development (SQL Azure Database)."
For a list of tools that can help with planning the migration of an application to Azure, see the "Assessment/Planning" section of "Azure Tools."
Managing, Monitoring, and Debugging Azure Applications
All storage and management subsystems in Azure use REST-based interfaces. They are not dependent on any .NET Framework or Windows operating system technology. Any technology that can issue HTTP or HTTPS requests can access Azure facilities.
To learn about the Azure managed and native library APIs, and the storage services REST API, see "API References for Azure."
The REST-based service management API can be used as an alternative to the Azure web management portal. The API includes features to work with storage accounts, hosted services, certificates, affinity groups, locations, and subscription information. For more information, see "Azure Service Management REST API Reference." In addition, Azure provides diagnostic services and APIs for activities such as monitoring an application's health. You can use the Azure Management Pack and System Center Operations Manager 2007 R2 to discover Azure applications, get the status of each role instance, and collect and monitor performance information, Azure events, and the .NET Framework trace messages from each role instance. For more information, see "Monitoring Azure Applications."
|Azure includes features that allow you to monitor and debug cloud-hosted services.|
You can also use the Windows Azure PowerShell Cmdlets to browse and manage Azure compute and storage services, automate deployment, and upgrade your Azure applications, as well as manage your diagnostics data.
For information about using the Azure built-in trace objects to configure diagnostics and instrumentation without using Operations Manager, and about downloading the results, see "Collecting Logging Data by Using Azure Diagnostics."
Chapter 7, "Application Life Cycle Management for Azure Applications" in the guide "Moving Applications to the Cloud" contains information about managing Azure applications.
Managing SQL Azure Databases
Applications access SQL Azure databases in exactly the same way they access locally installed SQL Server instances using the managed ADO.NET data access classes, Enterprise Library Data Access Application Block (DAAB), OData, native ODBC, PHP, Ruby, or JDBC data access technologies.
SQL Azure databases can be managed through the web portal, SQL Server Management Studio, Visual Studio 2010 database tools, and a range of other tools for activities such as moving and migrating data, as well as command-line tools for deployment and administration.
SQL Azure supports a management API as well as management through the web portal. For information about the SQL Azure management API see "Management REST API Reference."
Upgrading Azure Applications
After you deploy an application to Azure, you will need to update it as you change the role services in response to new requirements, code improvements, or to fix bugs. You can simply redeploy a service by suspending and then deleting it, and then deploy the new version. However, you can avoid application downtime by performing staged deployments (uploading a new package and swapping it with the existing production version), or by performing an in-place upgrade (uploading a new package and applying it to the running instances of the service).
For information about how you can perform service upgrades by uploading a new package and swapping it with the existing production version, see "How to Deploy a Service Upgrade to Production by Swapping VIPs in Azure."
For information about how you can perform in-place upgrades, including details of how services are deployed into upgrade and fault domains and how this affects your upgrade options, see "How to Perform In-Place Upgrades on a Hosted Service in Azure."
If you only need to change the configuration information for a service without deploying new code, you can use the web portal or the management API to edit the service configuration file or to upload a new configuration file.
Azure Subscription and Billing Model
To use Azure, you first create a billing account by signing up for Microsoft Online Services or through the Azure portal at https://windows.azure.com/. The Microsoft Online Services customer portal manages subscriptions to all Microsoft services. Azure is one of these, but there are others such as Business Productivity Online, Windows Office Live Meeting, and Windows Intune™ software and services.
This section is based on the information publicly available at the time of this writing.
Every billing account has a single account owner who is identified with a Windows Live ID. The account owner can create and manage subscriptions, view billing information and usage data, and specify the service administrator(s) for each subscription.
|The account owner and the service administrator for a subscription can use (and in many cases should use) different Live IDs.|
Administrators manage the individual hosted services for an Azure subscription using the Azure portal at https://windows.azure.com/. An Azure subscription can include one or more of the following:
- Hosted services, consisting of hosted roles and the instances within each role. Roles and instances may be stopped, in production, or in staging mode.
- Storage accounts, consisting of Table, BLOB, and Queue storage instances.
- CDN instances.
- SQL Azure databases and Data Sync service.
- SQL Azure Reporting Services instances.
- Access Control, Service Bus, and Cache service instances.
- Virtual Network Connect and Traffic Manager instances.
Figure 1 illustrates the Azure billing configuration for a standard subscription.
Azure billing configuration for a standard subscription
Estimating Your Costs
Azure charges are based on how you consume services such as compute time, storage, and bandwidth. Compute time charges are calculated on an hourly rate as well as a rate for the instance size. Storage charges are based on the number of gigabytes and the number of transactions. Prices for data transfer vary according to the geographic location you are in and generally apply to transfers between the Microsoft data centers and your premises, but not on transfers within the same data center.
To estimate the likely costs of an Azure subscription, see the following resources:
- Subscription overview for the various purchasing models such as the pay-as-you-go and subscription model, including a tool for measuring consumption, at http://www.microsoft.com/windowsazure/pricing/.
- Pricing calculator at http://www.microsoft.com/windowsazure/pricing-calculator/.
- TCO calculator at http://www.microsoft.com/windowsazure/offers/#tcoCompare-LB.
|You are billed for role resources that are used by a deployed service, even if the roles on those services are not running. If you don't want to get charged for a service, delete the deployments associated with the service.|
There is a great deal of information available about Azure in the form of documentation, training videos, and white papers. Here are some websites you can visit to learn more:
- The portal to information about Azure is at http://www.microsoft.com/WindowsAzure/. It has links to white papers, tools such as the Azure SDK for .NET, and many other resources. You can also sign up for an Azure account there.
- The Azure learning portal at http://www.microsoft.com/WindowsAzure/learn.
- Wade Wegner and Steve Marx have a series of Channel 9 discussions about Azure on Cloud Cover, located at http://channel9.msdn.com/shows/Cloud+Cover/.
- Find answers to your questions on the Azure Forum at http://social.msdn.microsoft.com/Forums/en-US/windowsazuredevelopment/threads
- Steve Marx is an Azure Technical Product Manager. His blog is at http://blog.smarx.com/. It is a great source of news and information on Azure.
- Wade Wegner is the Technical Evangelist Lead for Azure. His blog is full of technical details and tips. It is at http://www.wadewegner.com/.
- Azure Feature Voting backlog at http://www.mygreatwindowsazureidea.com to provide feedback, submit and vote on features requests.
- The community site for the patterns & practices series of guides at http://wag.codeplex.com/ provides links to online resources, sample code, hands-on labs, feedback, and more.
- The community site for this release at http://entlib.uservoice.com/forums/101257-windows-azure-integration-pack provides links to additional online resources, issue tracker and discussion forum.
Below are the links to references in this chapter:
- Microsoft Azure Guidance on CodePlex:
- Azure Features:
- Azure Offers:
- Building an Application that Runs in a Hosted Service:
- Creating Applications by Using a VM Role in Azure:
- Cloud Development:
- Azure Storage Services REST API Reference:
- Table Service Concepts:
- Table Service REST API:
- Understanding Block Blobs and Page Blobs:
- Blob Service REST API:
- Queue Service Concepts:
- Queue Service REST API:
- Azure Drive:
- SQL Azure Database:
- Microsoft Sync Framework Developer Center:
- Caching Service (Azure):
- Delivering High-Bandwidth Content with the Azure CDN:
- Connecting Local Computers to Azure Roles:
- Azure Traffic Manager:
- A Guide to Claims-Based Identity and Access Control (2nd Edition):
- Service Bus:
- SQL Azure Reporting:
- Azure Marketplace:
- Azure Marketplace:
- Azure Tools:
- Learn Azure and SQL Azure:
- Design. Code. Scale.:
- Developing Applications for Azure:
- Azure Training Kit:
- Development (SQL Azure Database):
- Azure Assessment/Planning:
- API References for Azure:
- Azure Service Management REST API Reference:
- Monitoring Azure Applications:
- Windows Azure PowerShell Cmdlets:
- Collecting Logging Data by Using Azure Diagnostics:
- Troubleshooting and Debugging in Azure:
- Debugging Applications in Azure:
- "Application Life Cycle Management for Microsoft Azure Applications" in Moving Applications to the Cloud:
- Management Portal for SQL Azure:
- Azure Tools:
- Management REST API Reference:
- How to Deploy a Service Upgrade to Production by Swapping VIPs in Azure:
- How to Perform In-Place Upgrades on a Hosted Service in Azure:
- Microsoft Online Services:
- "What are the Billing Basics of Azure?" in "Azure Platform"
- Accounts and Billing in SQL Azure:
- Subscription overview for the various purchasing models:
- Pricing calculator:
- TCO calculator:
- "How Much Will It Cost?" in Moving Applications to the Cloud:
- Moving Applications to the Cloud, 2nd Edition:
Last built: June 7, 2012