My simple Azure application, Magic Deck Statistics, makes use of two of the different types of Azure roles, web roles and worker roles.
Very simply, web roles are used to run web applications, via IIS. Worker roles do not have access to IIS (by default), and are used to run processes that don’t have user interaction.
In my application the worker role runs a daily job to download data from various sources and process it into a SQL database. The web roles deal with the presentation of this data, handling requests from visitors and querying the processed data.
The advantage of Web and Worker roles is that you don’t have to worry about the underpinnings of the setup. The server details are abstracted away and managed for you. You can very quickly scale up by provisioning additional web and worker roles through the management console.
If you need to deal with more complex software scenarios you can make use of the more general VM options, which allow you full configuration control over the VM. The cost here is that you must then maintain the entire machine, dealing with any patching and updating yourself.
Microsoft’s cloud offering is known as Windows Azure, and it is rapidly maturing. A couple of years ago it was clunky and hard to use, now it integrates quickly and easily with Visual Studio, making creating and deploying scalable cloud applications quick and easy.
There’s a free trial for new users, and those of us lucky enough to have MSDN subscriptions get a certain amount of compute and data space for free. You can run a number of websites at a free pricing tier, but for anything complex or customised, you will have to pay.
I’ve created a simple application, Magic Deck Statistics Viewer, to get a fuller understanding of Azure, and how it all fits together. My application collects information about decks used in the popular card game Magic: the Gathering, and allows users to generate charts based on the collected data.
It uses a single worker role to gather data once a day, and two web roles to manage the actual site. It’s developed in ASP.NET MVC4, using Visual Studio 2012. I make use of the Extra Small compute instances. These are very cheap to run (you can manage 8-9 on an MSDN subscription), and allow practice with the features of Azure without running up a large bill.
I’ll be covering the details of my Azure Exploration in further posts, and hopefully it will prove to be useful and enlightening to those just starting to investigate the cloud.