Where can I store my Data on Windows Azure?

So, You’re building a cloud app on Windows Azure are you? Where are you going to store your data? This is a question that comes down to architecture, scale and options. Considering I don’t know your architectural decisions, or how scalable your particular application, I guess that leaves me with only one topic to talk about, What are your options for storing data on Windows Azure?

Windows Azure is an open cloud platform which enables you to quickly build and deploy your applications using your existing skillset. This is reflected in the data options which are available for use on Windows Azure which are also hosted on Windows Azure.

Relational Databases on Windows Azure

Some Applications (or Developers) can’t live without a trusty relational database. We’ve got that.

MySQL

This option surprises many developers, but Windows Azure does have MySQL databases available for use.

MySQL is provided by a partner ClearDB who maintains multi-master and multi-master with multi-replica MySQL configurations. ClearDB combines advanced replication techniques, advanced clustering technology and a web service interface to provide MySQL Databases for your consumption.

If you create a Windows Azure Web Site using the Create with Database or From Gallery option in the Windows Azure Management Portal a Mercury sized database is being provisioned on your behalf.

MySQL Sizing Options

Pricing available on the Windows Azure Store on the ClearDB Website.

Package Name

Database Size

Max. Connection limit

I/O Performance

Mercury 20MB

4

Low
Venus 1GB

15

Moderate
Saturn 5GB

30

Moderate
Jupiter 10GB

40

High

MySQL on a Linux Virtual Machine

In addition to the ability to leverage a third-party service for using MySQL on Windows Azure, you can also leverage the new Virtual Machines feature. Follow the steps for setting up MySQL on an OpenSUSE Virtual Machine on Windows Azure.

Pricing for Linux Virtual Machines are available on the Windows Azure Pricing page.

SQL Database

Microsoft has created a cloud equivalent of SQL Server known as Windows Azure SQL Database (or SQL Database for short). SQL Database uses the same TDS Protocol as SQL Server which means all standard libraries or drivers [like the SQL Server Driver for PHP] work against SQL Database for Connectivity and Querying.

SQL Database Sizing Options

Pricing available on Windows Azure Pricing page under Data Management.

Database Size
100 MB
1 GB
10 GB
150 GB

As you can see above, SQL Database offers sizing tiers which acts as a starting point for your database size, additional database sizing between the tiers is offered at a discounted database rate as described in the SQL Database section of the Windows Azure Pricing page.

You may have also noticed that the maximum database size is 150GB, once you reach a database of this size it becomes necessary to shard your data using a technical known as SQL Federation.

SQL Server on a Windows Virtual Machine

If you need a large database (Scaled Vertically) or rely on a feature that is not currently present in SQL Database, it is possible to install SQL Server in a Windows Virtual Machine. Depending on the version of SQL Server you would like to use there are two great tutorials: Provisioning a SQL Server Virtual Machine on Windows Azure [which installs SQL Server 2012 from an image in the gallery] or Creating and Uploading a Virtual Hard Disk that Contains the Windows Server Operating System [which explains how to create a reusable operating system image, you’ll need to install SQL Server before running sysprep the VHD]

Unstructured Data (NoSQL) on Windows Azure

Unstructured Storage is becoming all the rage, which is understandable due to its ability to massively scale.

Windows Azure Table Storage

Windows Azure Table Storage is one of the three abstractions of Windows Azure Storage. Table Storage is an Entity-Attribute-Value model data store with a 100TB per account limit. Each subscription has 5 storage accounts by default, and more storage accounts can be added by calling customer support.

An entity in Windows Azure Table Storage is comprised of 3 required properties partition key, row key & timestamp and up to 252 additional properties. Properties can be one of the following data types Int32, Int64, String, Guid, DateTime, Double, Boolean or Byte Array.

MongoDB on Windows Azure

There are a few different ways that MongoDB is supported on Windows Azure which include in a Cloud Service, on a Virtual Machine or as a Service.

MongoDB in a Cloud Service

The creators of MongoDB, 10gen, have created a MongoDB installer which will install a MongoDB replica set in a Windows Azure Cloud Service. To do this they leverage a worker role in which their installer leverages a startup script to install the MongoDB Server. It also utilizes Local Storage as a cache before committing new transactions to Blob Storage.

To use the MongoDB in a Cloud Service configure and Deploy the MongoDB Installer.

MongoDB in a Virtual Machine

Obviously MongoDB can be installed on a Virtual Machine and can be exposed to the internet. There are two tutorials on installing a standalone instance of MongoDB on Windows Azure: Install MongoDB on a virtual machine running CentOS Linux in Windows Azure and Install MongoDB on a virtual machine running Windows Server 2008 R2 in Windows Azure.

If you would like to set up a highly available MongoDB replica set on Windows Azure, follow the instructions laid out in MongoDB on Windows Azure VM – Linux Tutorial or MongoDB on Windows Azure VM – Windows Installer,

MongoDB as a Service

Another option for MongoDB on Windows Azure is MongoDB as a Service provided by MongoLab. This service is [at time of writing] in preview and provides 500MB of storage for FREE. The MongoLab Preview is currently only available in the East US datacenter.

Preview Warning

We are pleased to be able to offer free databases running on Windows Azure. Be aware that both Windows Azure and MongoLab’s presence on Windows Azure are still in preview mode, and that these databases are not appropriate for production use. For example, we may need to take them down for maintenance from time to time without advance warning.

image

CouchDB on Windows Azure

Apache CouchDB is a JSON document database exposed over HTTP.

CouchDB comes with a suite of features, such as on-the-fly document transformation and real-time change notifications, that makes web app development a breeze. It even comes with an easy to use web administration console. You guessed it, served up directly out of CouchDB! We care a lot about distributed scaling. CouchDB is highly available and partition tolerant, but is also eventually consistent. And we care a lot about your data. CouchDB has a fault-tolerant storage engine that puts the safety of your data first.

BigCouch by Cloudant

Cloudant has expanded the base implementation of CouchDB in a new incarnation they are calling BigCouch. BigCouch as a Service is offered in the West US datacenter in a cluster Cloudant refers to Lagoon.

The Cloudant Data Layer collects, stores, analyzes and distributes application data across a global network of secure, high-performance data centers, delivering low-latency, non-stop data access to users no matter where they’re located.

BigCouch is chalked full of goodies including secondary indexes, lucene-based full text search, as well as built in replication and synchronization.

Cassandra on Windows Azure

Looking to build the next Netflix or Twitter? Run an elastic, decentralized and fault-tolerant Cassandra cluster on Windows Azure. Learn how to harness the power of Cassandra while a Node.js application in the tutorial Running Cassandra with Linux on Windows Azure and Accessing it from Node.js.

Choose your own Adventure

Have a favorite data store of your own? Why not try running it on Windows Azure? If you do, leave a comment below with a link off to a blog post explaining how you got it running.

Stay Cloudy my Friends…

6 Responses

Leave a Reply