Microsoft Windows Azure Development Cookbook

Realize the full potential of Windows Azure with this superb Cookbook that has over 80 recipes for building advanced, scalable cloud-based services. Simply pick the solutions you need to answer your requirements immediately.

Microsoft Windows Azure Development Cookbook

Cookbook

Neil MackenzieAugust 2011

Realize the full potential of Windows Azure with this superb Cookbook that has over 80 recipes for building advanced, scalable cloud-based services. Simply pick the solutions you need to answer your requirements immediately.

Book Details

ISBN 139781849682220

Paperback392 pages

Book Description

The Windows Azure platform is Microsoft's Platform-as-a-Service environment for hosting services and data in the cloud. It provides developers with on-demand computing, storage, and service connectivity capabilities that facilitate the hosting of highly scalable services in Windows Azure datacenters across the globe.

This practical cookbook will show you advanced development techniques for building highly scalable cloud-based services using the Windows Azure platform. It contains over 80 practical, task-based, and immediately usable recipes covering a wide range of advanced development techniques for building highly scalable services to solve particular problems/scenarios when developing these services on the Windows Azure platform.

Packed with reusable, real-world recipes, the book starts by explaining the various access control mechanisms used in the Windows Azure platform. Next you will see the advanced features of Windows Azure Blob storage, Windows Azure Table storage, and Windows Azure Queues. The book then dives deep into topics such as developing Windows Azure hosted services, using Windows Azure Diagnostics, managing hosted services with the Service Management API, using SQL Azure and the Windows Azure AppFabric Service Bus. You will see how to use several of the latest features such as VM roles, Windows Azure Connect, startup tasks, and the Windows Azure AppFabric Caching Service.

Table of Contents

Chapter 1: Controlling Access in the Windows Azure Platform

Introduction

Managing Windows Azure Storage Service access keys

Connecting to the Windows Azure Storage Service

Using SetConfigurationSettingPublisher()

Connecting to the storage emulator

Managing access control for containers and blobs

Creating a Shared Access Signature for a container or blob

Using a container-level access policy

Authenticating against the Windows Azure Service Management REST API

Authenticating with the Windows Azure AppFabric Caching Service

Chapter 2: Handling Blobs in Windows Azure

Introduction

Setting properties and metadata for a blob

Using blob directories

Creating and using a blob snapshot

Creating and using the root container for blobs

Uploading blocks to a block blob

Uploading a VHD into a page blob

Downloading a blob asynchronously

Optimizing blob uploads and downloads

Using retry policies with blob operations

Copying a blob with the Windows Azure Storage Service REST API

Leasing a blob using the Protocol classes in the Windows Azure Storage Client Library

Using the Windows Azure Content-Delivery Network (CDN)

Chapter 3: Going NoSQL with Windows Azure Tables

Introduction

Creating a table

Creating a data model and context for an entity

Using entity group transactions

Diagnosing problems when using the Table service

Handling concurrency with the Table service

Choosing a PartitionKey and RowKey for a table

Using continuation tokens and server-side paging

Performing asynchronous queries

Performing queries in parallel

Handling the WritingEntity and ReadingEntity events

Chapter 4: Disconnecting with Windows Azure Queues

Introduction

Managing Windows Azure queues

Adding messages to a queue

Retrieving messages from a queue

Storing large amounts of data for a message

Implementing a backoff when polling a queue

Identifying and handling poison messages

Chapter 5: Developing Hosted Services for Windows Azure

Introduction

Choosing the service model for a hosted service

Choosing which Windows Azure storage type to use

Configuring the service model for a hosted service

Hosting multiple websites in a web role

Providing a custom domain name for a hosted service

Implementing HTTPS in a web role

Sharing session state with the Windows Azure AppFabric Caching Service

Using local storage in an instance

Using startup tasks in a Windows Azure Role

Managing upgrades and changes to a hosted service

Handling changes to the configuration and topology of a hosted service

Authors

Neil Mackenzie

Neil Mackenzie has worked with computers for nearly 3 decades. He started his computer career doing large-scale numerical simulations for scientific research and business planning. Since then, he has primarily been involved in healthcare software and developing electronic medical record systems. He has been using Microsoft Azure since PDC 2008 and has used nearly all parts of the Microsoft Azure platform, including those parts that no longer exist. Neil is very active in the online Microsoft Azure community, contributing to the MSDN Microsoft Azure forums in particular. He is a Microsoft MVP for Microsoft Azure.

Table of Contents

Chapter 1: Controlling Access in the Windows Azure Platform

Introduction

Managing Windows Azure Storage Service access keys

Connecting to the Windows Azure Storage Service

Using SetConfigurationSettingPublisher()

Connecting to the storage emulator

Managing access control for containers and blobs

Creating a Shared Access Signature for a container or blob

Using a container-level access policy

Authenticating against the Windows Azure Service Management REST API

Authenticating with the Windows Azure AppFabric Caching Service

Chapter 2: Handling Blobs in Windows Azure

Introduction

Setting properties and metadata for a blob

Using blob directories

Creating and using a blob snapshot

Creating and using the root container for blobs

Uploading blocks to a block blob

Uploading a VHD into a page blob

Downloading a blob asynchronously

Optimizing blob uploads and downloads

Using retry policies with blob operations

Copying a blob with the Windows Azure Storage Service REST API

Leasing a blob using the Protocol classes in the Windows Azure Storage Client Library

Using the Windows Azure Content-Delivery Network (CDN)

Chapter 3: Going NoSQL with Windows Azure Tables

Introduction

Creating a table

Creating a data model and context for an entity

Using entity group transactions

Diagnosing problems when using the Table service

Handling concurrency with the Table service

Choosing a PartitionKey and RowKey for a table

Using continuation tokens and server-side paging

Performing asynchronous queries

Performing queries in parallel

Handling the WritingEntity and ReadingEntity events

Chapter 4: Disconnecting with Windows Azure Queues

Introduction

Managing Windows Azure queues

Adding messages to a queue

Retrieving messages from a queue

Storing large amounts of data for a message

Implementing a backoff when polling a queue

Identifying and handling poison messages

Chapter 5: Developing Hosted Services for Windows Azure

Introduction

Choosing the service model for a hosted service

Choosing which Windows Azure storage type to use

Configuring the service model for a hosted service

Hosting multiple websites in a web role

Providing a custom domain name for a hosted service

Implementing HTTPS in a web role

Sharing session state with the Windows Azure AppFabric Caching Service

Using local storage in an instance

Using startup tasks in a Windows Azure Role

Managing upgrades and changes to a hosted service

Handling changes to the configuration and topology of a hosted service

Alerts & Offers

Series & Level

We understand your time is important. Uniquely amongst the major publishers, we seek to develop and publish the broadest range of learning and information products on each technology. Every Packt product delivers a specific learning pathway, broadly defined by the Series type. This structured approach enables you to select the pathway which best suits your knowledge level, learning style and task objectives.

Learning

As a new user, these step-by-step tutorial guides will give you all the practical skills necessary to become competent and efficient.

Beginner's Guide

Friendly, informal tutorials that provide a practical introduction using examples, activities, and challenges.

Essentials

Fast paced, concentrated introductions showing the quickest way to put the tool to work in the real world.

Cookbook

A collection of practical self-contained recipes that all users of the technology will find useful for building more powerful and reliable systems.

Blueprints

Guides you through the most common types of project you'll encounter, giving you end-to-end guidance on how to build your specific solution quickly and reliably.

Mastering

Take your skills to the next level with advanced tutorials that will give you confidence to master the tool's most powerful features.

Starting

Accessible to readers adopting the topic, these titles get you into the tool or technology so that you can become an effective user.

Progressing

Building on core skills you already have, these titles share solutions and expertise so you become a highly productive power user.