16.6. Worker Roles

A worker role is Azure's version of a Windows service. Worker roles are used for continual or long-running tasks, such as processing data held in an Azure queue (we will look at Azure queues shortly). Worker roles cannot be accessed directly like a web role or ASP.NET page, but they do allow the creation of HTTP-based endpoints for inter-role communication. Please see the Azure samples' November training kit (www.microsoft.com/downloads/details.aspx?FamilyID=413e88f8-5966-4a83-b309-53b7b77edf78&displaylang=en), which contains a thumbnail image generator example.

In many Azure projects, you will want to use both web and worker roles. To add a worker role to an existing project, just right-click the ~/Roles/ directory, and then ...

Get Introducing .NET 4.0: with Visual Studio 2010 now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.